Files
oam/knowledge base/ai/gemini/cli.md
2026-02-13 00:44:18 +01:00

1.3 KiB

Gemini CLI

TODO

Open-source AI agent that allows to use Google Gemini from a terminal.
Can read and edit files, execute shell commands, and search the web.

  1. TL;DR
  2. Further readings
    1. Sources

TL;DR

Setup
# Install.
npm install -g '@google/gemini-cli'

# Run without installation.
docker run --rm -it 'us-docker.pkg.dev/gemini-code-dev/gemini-cli/sandbox:0.1.1'
npx '@google/gemini-cli'

# Configure API keys.
export GEMINI_API_KEY="YOUR_GEMINI_API_KEY"
Usage
# Start.
gemini

# Run inside a container.
# If installed locally.
gemini --sandbox -y -p "your prompt here"

# Headless mode.
gemini -p "What is fine tuning?"
echo "What is fine tuning?" | gemini

Further readings

Sources