Don't treat gemini like a chat box
The first win is a repo file diff, not a chat reply.
Installing gemini and chatting once is not a first win. A first win is a file change inside a git repo that git diff can show. To walk that diff on a shared board, use the header control to start a meeting
The search is Gemini CLI first successful run in a git repo. The package is @google/gemini-cli. On 2026-11-16 npm latest was 0.68.0; docs ask for Node.js 20+. Source: geminicli.com/docs.
Install until gemini is on PATH
- 1
npm global or npx
Stable:
npm install -g @google/gemini-cli(same as@latest). Skip a global install withnpx @google/gemini-cli. On macOS/Linux,brew install gemini-cliis documented. - 2
Check the binary
Open a new shell and run
gemini --version. If Node is below 20, upgrade the runtime. Do not grab random binaries. - 3
Do not start in an empty folder
Docs start the agent in the current directory.
cdinto a git repo, thengemini. Asking trivia in an empty folder never completes a first coding task.
Auth is the step before the chat box
Org licenses need a cloud project; paid keys use the API. See geminicli.com/docs/get-started/authentication.
| You are | Before launch | Check |
|---|---|---|
| Company Code Assist | export GOOGLE_CLOUD_PROJECT=… + gemini | Export the project ID first |
| Paid API key | export GEMINI_API_KEY=… | aistudio.google.com/apikey |
| Vertex production | GOOGLE_API_KEY + GOOGLE_GENAI_USE_VERTEXAI=true | Enterprise quota and compliance |
The first coding task that counts
- 1
Enter the repo, not $HOME
cdto the root that contains.git. Extra trees: officialgemini --include-directories ../lib,../docs. - 2
Make the prompt checkable
Skip “look at this.” Ask: add a failing test for X, then change the code until it passes. Success is a diff on disk, not “sure.”
- 3
Approve tools, then git
File and shell tools wait for you. After approve, run
git diffand the test command. Scripts can usegemini -p "…"; the first run should be interactive so you see the approval screen. - 4
Commit only hunks you read
The CLI writes the repo. Scope follows the prompt and trusted folders. Do not dump the tree in and commit blind.
cd your-git-repo
gemini --version
gemini
# first prompt: add a failing test for X, then make it pass
git diff
Command not found
Global npm bin missing from PATH, or Node < 20. Check which gemini and node -v.
Login spins or denies
The free personal lane moved. If you lack Code Assist or a paid key, follow the official Antigravity CLI migration—do not reinstall the same package.
It only chats
The prompt is vague, or a write tool was denied. Name one path plus a test, then approve a write once.
Path: official install →
geminiat the git root → one test-backed edit prompt →git diff. Trust localgemini --versionand geminicli.com/docs.
For remotes, see GitHub CLI login and PRs · Cursor project rules · create and join a room · wbroom.
npx versus a global install?
npx @google/gemini-cli runs once without a global bin. For daily use, npm install -g or brew install gemini-cli.
Can I still use a free Google account?
README: free individual and Google AI Pro/Ultra moved to Antigravity CLI on 2026-06-18. This package targets Code Assist licenses and paid API/Vertex keys.
What should the first prompt be?
Pick a small failure in the repo: add a test, change one implementation, run the existing test command. The bar is git diff, not a paragraph.
Does -p count as a first win?
gemini -p is for scripts. First run: interactive, so you see tool approval. Reuse the same prompt with -p later.