Skip to content

Add env guidance for PowerShell #50

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Merged
merged 1 commit into from
Mar 12, 2025
Merged
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
14 changes: 10 additions & 4 deletions docs/getting-started/windows.md
Original file line number Diff line number Diff line change
Expand Up @@ -90,19 +90,25 @@ npx mycoder "Your prompt here"
### Setting up API keys

1. **Temporary Environment Variables**:

From the command prompt (CMD):
```
set ANTHROPIC_API_KEY=your-api-key
```

2. **Persistent Environment Variables**:
In a PowerShell session:
```
$env:ANTHROPIC_API_KEY="your-api-key"
```

3. **Persistent Environment Variables**:
- Right-click on "This PC" or "My Computer"
- Select "Properties"
- Click "Advanced system settings"
- Click "Environment Variables"
- Under "User variables", click "New"
- Add your API key (e.g., ANTHROPIC_API_KEY as variable name)

3. **Using .env File**:
4. **Using .env File**:
- Create a file named `.env` in your project directory
- Add your API key: `ANTHROPIC_API_KEY=your-api-key`

Expand All @@ -122,4 +128,4 @@ MyCoder can use a browser for research. On Windows:
- **Node Version**: Ensure you're using Node.js 20+
- **Path Issues**: Make sure npm global bin directory is in your PATH

If you encounter any other issues, please check our [Discord community](https://discord.gg/5K6TYrHGHt) for help.
If you encounter any other issues, please check our [Discord community](https://discord.gg/5K6TYrHGHt) for help.