Complete your Gueini Cli preparation guide for your station
Have you ever wished an Amnesty International assistant within your peripheral window? Well, your dream may be really because Google has just released Gemini Cli. In this tutorial, I will show you everything you need to know about this new artificial intelligence agent. This new source. We will cover how it is used, pricing, and some useful tips and tricks. So, if you are ready, let’s start! 😉
What is the cli?
Gemini Cli is a free and open source agent that works directly at your station. This powerful tool brings Google Gemini models to your command line, allowing the natural language to interact to complete the work. You can ask him:
- Write and explain the code.
- File editing.
- Explanation of errors.
- Run the shell orders.
- And much more!
You don’t have to switch constantly between your web application and your station. And the best part? that it freeWith no complex setting.
Start with Gemini Cli
Step 1: Install Gemini Cli on Linux
You can install Gemini is complete on Linuxand MacAnd Windows. All the preparation we will do inside the station. I use Linux, but for Mac and Windows, orders are almost the same, so you can follow my steps.
To start, make sure you have node.js 18 or higher. You can check this by running:
node -v
If you don’t have that, use the next order to install it:
sudo apt update && sudo apt install nodejs npm
Then, I installed the world in the world with:
npm install -g @google/gemini-cli
If you don’t want to install it worldwide, you can also use:
npx https://github.com/google-gemini/gemini-cli
Step 2: Run and log in
After installation, write only:
gemini
Next, you need to log in with your Google account.
This allows you to access a free assistance license to help the Gemini Code, which includes:
- Access to Gemini 2.5 Pro.
- A symbolic context window of one million million.
- 60 model requests per minute.
- 1000 Takes daily for free.
You can also use the Google Ai Studio Ai Key if you prefer it.
Step 3: Try it
You are now ready to start asking questions and running tasks. You can ask the agent to create a project, fix errors, explain the code in specific files, etc. Be sure to run the agent inside the project folder.
> What does the file index.js do?
Read the file, analyze it, and gave a clear explanation.
> Add error handling to index.js
You can also turn on Shell orders directly using !
Likewise:
!ls -al
Create a simple app with Google Cli
Now that we are all prepared, let’s ask artificial intelligence to create a simple tasks app using HTML, CSS and JavaScript. I will write “Create a simple app using JS and Simple HTML” in Gemini Cli. “ Watch the video to watch a step -by -step process.
Watch Youtube:
Gemini Cli has some compact tools within reach. You can use orders such as:
Overview of Gemini Cli tools
- reading ((
ls
). It lists files and folders in a guide – just like the shellls
He orders. - Readfile ((
read-file
). Read the full content of one file, useful for summaries or analysis. - Readanyfiles ((
read-many-files
). He reads many files simultaneously, usually matchs the globe style (for example, everything.js
Files) - Findfiles ((
glob
). Looking for files by style (for example, looking for everyoneconfig.json
Through your project). - Searchtext ((
grep
). Looking inside the files of the text, such as finding allTODO
comments. - Restricting ((
edit
). Code changes are applied via Diffs. Gemini and ask about approval before applying it. - Writing ((
write-file
). It creates new files (for example,README.md
) With the content offered by the user. - coincidence ((
shell
). He manages the orders he earns with!
(For example ,!npm test
) Directly at the station. - Webfetch ((
web-fetch
). It attends the web content (HTML or JSON), enabling Gemini to analyze external data. - Googlesearch ((
web-search
). Google research leads to ground responses with information in the real world (for example, an explanation of a mistake). - Memory save ((
memoryTool
). Store facts or preferences during the session (such as “I am the best synchronous/waiting”) to improve consistency
To see all available tools, you can use /tools
He orders.
Advanced features
You can add specific instructions to the IQ Agency for a specific project by creating a file Gemini.md A file in the root guide for your project. Inside this file, you can determine the project rules, code patterns and tools that the agent must use. This ensures that the created code corresponds to your project standards.
Google Cli MCP integration
For most daily uses, compact tools are sufficient. But what if you want to do Gemini Cli something very special in the field, such as interacting with specific application programming facades or using a specialized model (less photo generator or safety analysis tool)? This is the place MCP (Form Context Protocol) It comes in.
MCP is mainly an open standard that allows developers Add new tools/capabilities to artificial intelligence by running a server The Cli can communicate with. In Gemini Cli, you can configure “MCP servers” in the JSON settings file, and Cli will treat those additional tools you can use.
How to prepare a MCP server in Google Cli
For example, I will show you how to prepare GitHub McP Server in Gemini Cli.
Inside your project folder, create a folder using:
mkdir -p .gemini && touch .gemini/settings.json
Inside the file, add the following symbol:
{
"mcpServers": {
"github": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-github"],
"env": { "GITHUB_PERSONAL_ACCESS_TOKEN": "[YOUR-TOKEN]" }
}
}
}
after that /quit
From Gemini Cli, then reopen it.
He writes /mcp
The matter, and you will see a list of Gaytap tools.
Now you, an agent, you can interact with Gyfap. This is simple! Prevailing
Gemini Cli pricing
You can try it for free for personal use, but there is also a paid version based on the use of the distinctive symbol.
Free preview layer
- Assign: Free with Google account
- border: until 60 requests/min and 1000 requests/day
- Wonderful for individual developers and use on a small scale
Use the paid API key / API
- Use yourself Gemini key API For higher use
- Bills based on consuming codes (based on form and use)
Foundation options
- Available Help the Gemini icon or the institution Plan
- It includes advanced features such as governance, audit records and shared shares
conclusion
As you can see, Gemini Cli is a truly powerful tool with a lot of capabilities. I am excited to see how I will use it in the daily workflow.
If you write a code, correct things or manage files often, this tool is worth verifying.
If you have any notes, please share it in the comments below. 😉
Cheers!