THIS IS AN OPEN SOURCE FORK OF THE GEMINI-CLI COMPATIBLE WITH ANY OPEN AI COMPATIBLE API KEY OR LOCAL MODELS LIKE GEMMA AND IS IN NO WAY AFFILIATED OR ENDORSED BY GOOGLE
THIS IS NOT AN OFFICIAL GOOGLE PRODUCT AND YOU UNDERSTAND THAT ANY USE IS AT YOUR OWN RISK
Gemma CLI is an open-source AI agent that brings the power of Gemini directly into your terminal. It provides lightweight access to Gemini, giving you the most direct path from your prompt to our model.
Learn all about Gemma CLI in our documentation.
# Using npx (no installation required)
npx @gemma/gemma-clinpm install -g @gemma/gemma-clibrew install gemma-clisudo port install gemma-cli# Create and activate a new environment
conda create -y -n gemma_env -c conda-forge nodejs
conda activate gemma_env
# Install Gemma CLI globally via npm (inside the environment)
npm install -g @gemma/gemma-cligemmagemma --include-directories ../lib,../docsgemma -m gemma-2.5-flashGet a simple text response:
gemma -p "Explain the architecture of this codebase"For more advanced scripting, including how to parse JSON and handle errors, use
the --output-format json flag to get structured output:
gemma -p "Explain the architecture of this codebase" --output-format jsonFor real-time event streaming (useful for monitoring long-running operations),
use --output-format stream-json to get newline-delimited JSON events:
gemma -p "Run tests and deploy" --output-format stream-jsoncd new-project/
gemma
> Write me a Discord bot that answers questions using a FAQ.md file I will providegit clone https://github.com/BWS1900/gemma-cli
cd gemma-cli
gemma
> Give me a summary of all of the changes that went in yesterdaySee official Gemini-CLI Documentation.
Configure MCP servers in ~/.gemma/settings.json to extend Gemma CLI with
custom tools:
> @github List my open pull requests
> @slack Send a summary of today's commits to #dev channel
> @database Run a query to find inactive users
We welcome contributions! Gemma CLI is fully open source (Apache 2.0), and we encourage the community to:
- Report bugs and suggest features.
- Improve documentation.
- Submit code improvements.
- Share your MCP servers and extensions.
See the Official Gemini-CLI for details.
- License: Apache License 2.0
Forked with β€οΈ by the open source community
