Aider
Configure Aider, the terminal-based AI pair programmer, to use Revo Mail for powerful code generation and modification.
What This Does
Aider is a command-line tool that lets you edit code through natural language conversations. It can read your codebase, make precise edits, and even commit changes to git. By connecting Aider to Revo Mail, you gain access to powerful models while managing all your AI spending through a single account.
Setup
Step 1: Install Aider
pip install aider-chatOr with pipx for isolation:
pipx install aider-chatStep 2: Set Environment Variables
Aider uses OpenAI-style environment variables. Set them in your shell:
export OPENAI_API_BASE="https://api.revomail.io/v1"
export OPENAI_API_KEY="YOUR_Revo Mail_API_KEY"Replace YOUR_Revo Mail_API_KEY with your actual key from revomail.io/keys.
Step 3: Persist the Configuration
Add the exports to your shell profile for persistence:
Zsh (~/.zshrc):
echo 'export OPENAI_API_BASE="https://api.revomail.io/v1"' >> ~/.zshrc
echo 'export OPENAI_API_KEY="YOUR_Revo Mail_API_KEY"' >> ~/.zshrc
source ~/.zshrcBash (~/.bashrc):
echo 'export OPENAI_API_BASE="https://api.revomail.io/v1"' >> ~/.bashrc
echo 'export OPENAI_API_KEY="YOUR_Revo Mail_API_KEY"' >> ~/.bashrc
source ~/.bashrcStep 4: Launch Aider with Your Model
Navigate to your project directory and start Aider:
cd /path/to/your/project
aider --model gpt-5.4Or specify a different model:
aider --model gpt-5.3-codex
aider --model gemini-3.1-pro
aider --model glm-5-turboStep 5: Add Files to the Chat
Once Aider is running, add the files you want to work on:
> add main.py utils.pyThen start chatting naturally about what changes you want.
Recommended Models for Aider
| Task | Model | Rationale |
|---|---|---|
| General development | gpt-5.3-codex | Optimized for code edits |
| Complex refactoring | gpt-5.4 | Best reasoning for architectural changes |
| Large codebases | gemini-3.1-pro | 1M context fits more files |
| Quick fixes | glm-5-turbo | Fast iteration, low cost |
Command Reference
| Command | Description |
|---|---|
aider --model gpt-5.4 | Start with specific model |
aider --list-models | Show available models |
aider file1.py file2.py | Start with specific files |
aider --auto-commits | Auto-commit changes |
aider --no-auto-commits | Disable auto-commits |
Troubleshooting
"API key not found" error
- Ensure
OPENAI_API_KEYis exported in your current shell - Run
echo $OPENAI_API_KEYto verify it's set
"Model not available" error
- Use the exact model slug from the Models reference
- Try
aider --list-modelsto see what Aider detects
Connection timeout
- Verify
OPENAI_API_BASEis exactlyhttps://api.revomail.io/v1 - Check your network can reach
api.revomail.io
Slow responses on large files
- Use a model with larger context:
gemini-3.1-pro - Add fewer files to the chat context at once
Changes not applying correctly
- Ensure files are added to the chat with
add <filename> - Check that Aider has write permissions in the directory
Notes
- Aider works best when you add relevant files to context before asking for changes
- It integrates with git — commits are created automatically unless disabled
- Use
--dry-runto preview changes without modifying files - All token usage appears in your Revo Mail dashboard immediately
- For sensitive projects, consider using
--no-auto-commitsto review before committing