🧱 aider

AI pair programming at the command line — no IDE required

aider curl fabric fzf gh Copilot jq ollama ripgrep sgpt tmux

What Is aider?

aider is an open-source AI coding assistant that runs entirely in your terminal. Unlike GitHub Copilot, which lives inside an editor, aider works directly with your files from the shell. You point it at one or more files, describe what you want changed, and it edits the files — showing you a diff before committing to git.

For a Linux SysAdmin, that means you can work on bash scripts, Python tools, config files, and HTML pages from the same terminal you're already in, using the same AI assistance that developers get in fancy IDEs.

aider supports multiple AI backends — Claude, GPT-4, and others — so you can choose the model you trust for the task at hand.

"aider treats your files as first-class citizens. It reads them, edits them, and commits the changes — all from the terminal, all under your control."

💰 Cost & Licensing

aider itself is free and open source (Apache 2.0 license). The cost comes from the AI API you connect it to:

Note: For occasional use, API costs are typically a few cents per session. Heavy daily use can add up — track your usage in the provider's dashboard.

🔧 Installation

aider is a Python package. Install it with pip:

pip install aider-chat

On systems where you want to avoid touching the system Python:

# Using pipx (recommended — installs in an isolated environment) pipx install aider-chat # Or create a virtual environment python3 -m venv ~/aider-env source ~/aider-env/bin/activate pip install aider-chat

Verify the install:

aider --version

Set your API key (add to .bashrc or .bash_profile):

# For Anthropic Claude export ANTHROPIC_API_KEY=your-key-here # For OpenAI export OPENAI_API_KEY=your-key-here
Tip: Get your Anthropic API key at console.anthropic.com. New accounts receive free credits to get started.

💻 Basic Usage

Starting a session

Navigate to your project directory and launch aider with the files you want to work on:

cd /var/www/html/LessonPlans/AI/ aider --model claude-sonnet-4-20250514 collaboration/index.html deep-dive/index.html

aider reads the files, starts an interactive session, and waits for your instructions.

Making changes

Just describe what you want in plain English at the prompt:

> Add a nav breadcrumb at the top of both files linking back to AI Home > The footer date says March 3 — update it to March 12, 2026 > Add a warning box after the installation section reminding users to never commit API keys to git

aider proposes the edits as a diff, applies them to your files, and — if you're in a git repo — commits the changes automatically with a generated commit message.

Adding files mid-session

> /add check_ai_tree.sh

Viewing what files are loaded

> /ls

Undoing the last change

> /undo
Tip: Type /help inside aider for a full list of slash commands.

🤖 Choosing Your Model

aider works with several models. For SysAdmin work:

# Specify model at launch aider --model claude-sonnet-4-20250514 myfile.sh # Or set a default in ~/.aider.conf.yml model: claude-sonnet-4-20250514

📝 SysAdmin Use Cases

Bash script refactoring

Load an existing script and ask aider to improve it:

aider check_ai_tree.sh > Add a --dry-run flag that shows what would be reported without making any changes > The MISSING_LINKS array is getting large — refactor the reporting section into its own function called report_missing()

Multi-file edits

aider can edit multiple files in a single instruction — useful when a change needs to be consistent across several pages:

aider deep-dive/*.html > Update the footer date to March 12, 2026 in all loaded files

Documentation generation

aider check_ai_tree.sh README.md > Read the script and write a README section explaining all the flags, output sections, and example usage

Config file work

aider /etc/httpd/conf.d/mysite.conf > Add a redirect rule that sends all HTTP traffic to HTTPS, preserving the path and query string
Important: When working on live config files, make a backup first. aider's /undo works within the session, but having a dated backup is good practice regardless.

🔐 Git Integration

aider is designed around git. By default, every change it makes is committed to the local repo with an auto-generated message. This gives you a complete history of every AI-assisted edit.

Tip: If your project isn't in git yet, git init before starting aider. It takes ten seconds and gives you a safety net for the entire session.

✅ Strengths & Limitations

Works Well

  • Bash script editing and refactoring
  • Multi-file consistent edits
  • Explaining what existing code does
  • Adding features to existing scripts
  • HTML/CSS edits across multiple pages
  • Writing documentation from code
  • Works entirely in the terminal
  • Open source — no vendor lock-in

Watch Out For

  • Large codebases eat context fast
  • API costs can surprise heavy users
  • Auto-commits need git discipline
  • Local models weaker than cloud models
  • Not a replacement for understanding the code
  • May miss site-specific conventions

📊 Craig's Take

aider is the tool on this list that most directly maps to how SysAdmins already work. No IDE, no browser extension, no subscription tied to a specific editor — just Python, an API key, and your existing files.

The git integration is the killer feature. Every AI-assisted change is a commit. You can review the diff, revert it, or cherry-pick it just like any other commit. That's the kind of auditability a SysAdmin can trust.

The multi-file editing is genuinely useful for site maintenance work. Telling aider "update the footer date in all these HTML files" and watching it do it correctly across a dozen files in one shot — that's the 9x efficiency multiplier in action.

"aider doesn't ask you to change how you work. It meets you at the terminal, where you already are."

🔗 Resources