Beginning with the Gemini command line interface (CLI)

by Brenden Burgess

When you buy through links on our site, we may earn a commission at no extra cost to you. However, this does not influence our evaluations.

Google recently published The Gemini Cli, a powerful command line designed to overeat developers' workflows with AI. Whether you are working on massive code bases, automating tedious tasks or you generate new applications from sketches and PDF, Gemini CLI brings direct multimodal intelligence to your terminal.

With Gemini Cli, you can:

  • Request and modify the major code bases, even beyond the standard 1m standard context window.
  • Generate applications from visual entries such as PDFs or design sketches.
  • Automate operational workflows – from the management of traction requests to the management of REBASES.
  • Connect external tools and MCP servers, including Imagen, Veo and Lyria for the generation of media.
  • Use Google Search as a grounding tool, directly in your terminal.

In this tutorial, we will guide you to install it, configure and start using Gemini Cli to improve your daily developer tasks.

Installation of the JS knot

To start, you will have to install Node.js on your system:

  • Go to nodejs.org And download the latest LTS version.
  • Run the installation program.
  • Use the default settings and complete the installation.

Installation and use of air conditioning

To install the GA Gemini, run the following command:

npm install -g @google/gemini-cli

Once installed, it can be initialized by performing the following code simple in the terminal

During the first race, you will be invited to:

  • Choose a color theme For the CLI interface.
  • Authenticate With your personal Google account – this allows you to access Gemini with generous use limits: 60 requests per minute And 1,000 requests per day.

You are now ready to start using Gemini Cli to improve your development workflow!

If you need to access a specific gemini model or if you want higher use limits, you can use your own API key.

  • Generate a key from Google Ai Studio.
  • Define it as an environment variable in your terminal by operating:
export GEMINI_API_KEY="YOUR_API_KEY"

Replace your_api_key with the real key you have generated. This allows Gemini Cli to authenticate by using your key instead of your personal Google account.

Ask a Github repo with Gemini

Once everything is configured, we will test it with a Github repo

Run the following command to clone the repo GitHub Marktechpost containing several AI tutorials

git clone https://github.com/Marktechpost/AI-Notebooks.git
cd AI-Notebooks

Once in the A-Notebooks folder, run the next command to execute the air conditioning

It will launch the air

AD 4nXdcM206CftI5A pwup oCwP5JFXk2M nIfwfsAp7

Summary The different standard tutorials

To start, let's try a simple prompt:

Give an overview of the different tutorials in this repository

GEMINI CLI will read the Readme.md file – assuming it contains details on tutorials and will generate a concise summary according to this information.

AD 4nXcOb7V9m38oECu

Explain the different files in a sub-folder

To refer to a specific directory or file in your prompt, use the @ Symbol followed by the folder or file name. Gemini Cli also supports automatic completion, so when you type @It will automatically suggest the available files and folders.

Let's tend that with the following prompt:

@A2A_Simple_Agent briefly explain the different files in this folder and how they work together to implement the A2A agent. Focus only on the .py files and the README.md file
AD 4nXfOqSxAMNN31fdwwCplDLaQCmtredZhLLRjWKEXpldM70d9R 4dbziGvXNDOl54kQtoYtXPr9O76LAZuZmU6I7wl7FcS1kQvxtU

Execute a Git command

Gemini CLI can also execute Shell commands directly from your prompts.

How many git commits have been made so far

When performing an order like this, Gemini will be:

  • Ask for your authorization before executing it.
  • Run the Shell command safely.
  • Recover automatically and display the result.
AD 4nXdnjGquqRUf0a0WtOndQN3JIm1TMCphKwHqAJQ

Memory update

We can also manage the educational context of AI using the /memory order

/memory add This Git repository contains multiple self-contained tutorial projects demonstrating how to use the Gemini CLI and build agent-based systems. Each folder (e.g., A2A_Simple_Agent) focuses on a specific concept like agent communication, tool use, or integration patterns. When asked, summarize or build on individual tutorials while keeping their scope isolated.
AD 4nXfRksrVLai JRNvEhDJGS4eF0Qyh1jC5MBl8b1tiPEibMeAj aVtm66TuEqonA5mCti1SywYN ECnHA9D

Statistics verification

THE / Statistics The order in Gemini Cli provides a detailed summary of your current session. It shows key measures such as the total use of tokens, any saving of cache tokens (when available) and the overall duration of the session. This is useful for monitoring your use effectiveness and understanding how the model is used during your workflow.

AD 4nXdOQ6S9TV62JSvktUJ 2yBpRBUlyo9DqQKlOACGwfQ5 G2zJMPB1JHqnCsBviJkqdTonOLM3buVSuEFZM5thdSpzVGemjlgNw2jG2WK1VkxN

Leave the session

You can finish your GA Gemini session at any time using the /to leave order. Once you leave, the CLI will display a session summary, including the total tokens used, the duration of the session and ventilation of the entry and exit tokens.

Upon reading

To explore the full range of commands, see the GEMINI CLAIG. There are many powerful commands that make Gemini cls a versatile tool for developers. In this tutorial, we only scraped the surface to give you a basic overview of its basic characteristics. For more details and updates, visit the official GEMEAUX CLA GITHUB deposit.


PASSPORT SIZE PHOTO

I graduated in Civil Engineering (2022) by Jamia Millia Islamia, New Delhi, and I have a great interest in data science, in particular neural networks and their application in various fields.

a sleek banner advertisement showcasing

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.