Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .env.example
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
# OpenRouter API key (https://openrouter.ai/keys). OPENAI_API_KEY also accepted.
# Copy this file to ~/.gcode/.env, then edit the key value.
OPENROUTER_API_KEY=sk-or-your-openrouter-key-here
5 changes: 3 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,12 @@
git clone https://github.com/shauryagangrade/GCode.git
cd GCode
pip install -e .
cp .env.example .env
mkdir -p ~/.gcode && cp .env.example ~/.gcode/.env
gcode
```

You will need an OpenRouter API key. Copy the `.env.example` file, name it `.env`, and fill in your `OPENROUTER_API_KEY`.
You will need an OpenRouter API key. Copy the `.env.example` file to
`~/.gcode/.env` and fill in your `OPENROUTER_API_KEY`.

---

Expand Down
10 changes: 9 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,15 @@ pip install -e .

## Setup

Copy `.env.example` to `.env` and add your OpenRouter API key:
GCode reads your API key from `~/.gcode/.env` (not a project-root `.env`).
Create it from the template and add your OpenRouter API key:

```bash
mkdir -p ~/.gcode
cp .env.example ~/.gcode/.env
```

Then edit `~/.gcode/.env`:

```
OPENROUTER_API_KEY=sk-or-...
Expand Down