Gemini CLI Integration

Gemini CLI is Google's free AI coding assistant for the command line.

Overview

PropertyValue
Tool Namegemini
Binarygemini
TierFree
Capabilitiescoding, simple-qa
Config Path~/.gemini/settings.json

Installation

npm install -g @anthropic-ai/gemini-cli
# or
brew install gemini-cli

Verify installation:

gemini --version

Configuration in Murmur

# ~/.mur/config.yaml
tools:
  gemini:
    enabled: true
    binary: gemini
    tier: free
    capabilities: [coding, simple-qa]
    flags: []

When Murmur Routes to Gemini

Gemini is selected for:

  • Simple questions (complexity < 0.5 in auto mode)
  • Quick explanations - "what is X?", "explain Y"
  • Basic coding - simple functions, snippets
  • Cost savings - when you want free usage

Sync Features

MCP Servers ✅

mur sync mcp

Syncs to ~/.gemini/settings.json.

Hooks ✅

mur sync hooks

Gemini CLI hook events:

Murmur EventGemini Event
UserPromptSubmitBeforeAgent
StopAfterAgent
BeforeToolBeforeTool
AfterToolAfterTool

Patterns ✅

mur learn sync

Patterns sync to Gemini's instruction context.

Skills ✅

Skills sync to Gemini's configuration.

Advantages

Free Usage

No API costs for most tasks. Perfect for:

  • Learning and experimentation
  • Simple Q&A
  • Quick code snippets
  • Documentation lookup

Fast Responses

Gemini tends to be faster for simple queries.

Good for Simple Tasks

Excellent for straightforward coding tasks that don't need Claude's advanced reasoning.

Limitations

  • Less capable for complex architecture tasks
  • May not handle nuanced debugging as well
  • Tool use capabilities are more limited

Direct Usage

gemini "write a function to reverse a string"

Or through murmur:

mur search "reverse a string"

Cost Savings

With murmur's smart routing:

mur stats
Cost Analysis:
  Saved by routing: $8.20 (66 prompts → free tool)

Every simple question routed to Gemini instead of Claude saves money.

Troubleshooting

Gemini Not Found

which gemini
# If not found:
npm install -g @google/gemini-cli

Rate Limiting

Gemini CLI has generous free limits, but if you hit them:

  1. Wait for reset (usually hourly)
  2. Use Claude Code directly for urgent tasks

Config Sync Issues

Ensure ~/.gemini/ directory exists:

mkdir -p ~/.gemini
mur sync all

See Also