Elevate your workflow with a powerful, open-source coding agent.
The Gemini Command Line Interface is an **open-source AI agent** built by Google. It utilizes the Gemini model's advanced **ReAct** (Reason and Act) architecture and local tool-use capabilities to perform complex, multi-step tasks—including code generation, debugging, cross-file editing, and project analysis—all directly from your local terminal. This positions it as the modern, powerful successor to the **OpenAI Codex CLI**.
Ensure you have **Node.js (v18+)** and **npm** installed. We recommend using nvm to manage versions, or brew install node if you prefer Homebrew.
$ brew install node
# Install Gemini CLI globally using npm
$ npm install -g @google/gemini-cli
Run the gemini command to launch the interactive session. The CLI will prompt you for authentication upon first run.
$ gemini
export GEMINI_API_KEY="YOUR_KEY"
template <typename T>
class Stack {
private:
struct Node { ... };
public:
void push(T data);
T pop();
};