Gemini-CLI Masterclass | The Only Guide You Need | Gemini 2025
Shishir Srivastav
View ChannelAbout
No channel description available.
Latest Posts
Video Description
The ultimate, start-to-finish guide to Gemini CLI, follow along as we install, authenticate, configure settings.json, use built-in tools, and run Gemini non-interactively. Perfect for beginners and devs who want a single, complete reference. ## What’s inside: - Fast install (Cloud Shell) - Auth (OAuth options) - Settings.json - Shell mode - Custom commands - Running commands, non-interactive mode, - MCP setup ## Official resources to follow along: - Codelab for Hands-on with Gemini CLI: https://codelabs.developers.google.com/gemini-cli-hands-on?hl=en#0 - Gemini CLI repo: https://github.com/google-gemini/gemini-cli ## Connect with me: 🐦 Twitter/X: https://x.com/shishir_who 📸 Instagram: https://instagram.com/programmatic.ly 📝 Tech Blog: https://hashnode.com/@ShishirSrivastav 💻 GitHub: https://github.com/Shishir420-GIT 💼 LinkedIn: https://linkedin.com/comm/mynetwork/d... 🎯 Book a Call: https://topmate.io/shishir_srivastav Subscribe for more AI & tech content! If this helped, smash Like, Subscribe, and drop a comment with what you want next? demo automations, GitHub Actions, or advanced tool usage? Timestamps: 00:00 - Intro & What is Gemini CLI? 01:00 - Free tier explained (limits & token usage) 02:20 - Tools overview: Google Search vs Web Fetch 03:30 - Starting Google Cloud Lab environment 04:30 - Creating a new project in GCP 05:30 - Setting up billing & free credits 06:30 - Launching Google Cloud Shell 07:10 - Starting Gemini CLI for the first time 08:10 - Fixing "Gemini command not found" error (npm install) 09:30 - Creating a project folder for Gemini CLI 10:30 - Running Gemini inside project folder 11:30 - Authentication: Google login, API Key, Vertex AI 13:30 - Setting Project ID in gcloud 14:30 - Understanding `settings.json` file 16:30 - User-level vs Project-level configs 18:00 - Example of MCP server config in settings.json 19:10 - First Gemini CLI interaction (Google Search) 21:00 - Commands & shortcuts (/quit, /m, etc) 22:00 - Changing models in Gemini CLI 23:00 - Non-interactive mode with `-p` flag 24:20 - Handling errors (quota exhausted, fallbacks) 25:00 - Using YOLO flag (auto-accept commands) 26:20 - Built-in tools: edit, read, write, search 27:20 - Viewing available MCP servers 28:10 - Example: Search + Write results to file 29:20 - Reading files with Gemini CLI 30:00 - Shell mode (! commands inside Gemini) 31:20 - What is MCP protocol & why it matters 33:00 - Adding custom MCP servers in settings.json 35:02 - Creating a GitHub Personal Access Token (PAT) 35:47 - Token permissions, expiry & repo access setup 36:34 - Generating & pasting the PAT into `settings.json` 37:06 - Validating token & reloading Gemini CLI 38:10 - Testing GitHub MCP connection with `/mcp` 38:58 - Verifying GitHub MCP: fetching username & profile 39:31 - Why & when to use MCP servers (GitHub, Firebase, Workspace) 40:32 - MCP toolbox example (databases, Google Workspace MCPs) 41:05 - Customizing the `Gemini.md` file (personas, memory, context) 42:44 - Creating and editing a new `Gemini.md` file 44:40 - Restarting Gemini to load new memory configs 45:34 - Creating custom commands in Gemini CLI 46:45 - Example: Adding `/refactor` command 48:19 - Testing & verifying custom command setup 50:10 - Recap: Project setup, tools, prompts, shell commands, MCPs, memory, and custom commands 52:00 - Use case: “Pair Coding with Gemini CLI” demo prompt 53:08 - Final thoughts, resources & next steps
Gemini CLI Gear You Need Now
AI-recommended products based on this video

BOSGAME Linux Mini PC, Intel 12th N100 16GB DDR4 RAM 512GB SSD Linux Server Computers Preinstalled Ubuntu 22.04,Support 4K Triple Display/USB3.2/WiFi 5/2.5GbE

OWC 64GB DDR5 4800 PC5-38400 CL40 2Rx4 288-pin 1.1V ECC Registered RDIMM Memory RAM Module Upgrade Compatible with Dell PowerEdge R6625 R760 R7615 R7625

OWC 64GB DDR5 4800 PC5-38400 CL40 2Rx4 288-pin 1.1V ECC Registered RDIMM Memory RAM Module Upgrade Compatible with Dell PowerEdge R660XS R760XS

Dell SSD 512GB Class 35 M.2 2230 NVMe PCIe 3.0 Gen 3x4 Solid State Drive SNP112233P/512G AB292881
![SAMSUNG 870 EVO SATA III SSD 4TB 2.5” Internal Solid State Drive, Upgrade PC or Laptop Memory and Storage for IT Pros, Creators, Everyday Users, MZ-77E4T0B/AM [Canada Version]](https://m.media-amazon.com/images/I/71W2nK7LUrL._AC_UL960_FMwebp_QL65_.jpg)
SAMSUNG 870 EVO SATA III SSD 4TB 2.5” Internal Solid State Drive, Upgrade PC or Laptop Memory and Storage for IT Pros, Creators, Everyday Users, MZ-77E4T0B/AM [Canada Version]

Samsung 990 EVO Plus - 4TB PCIe Gen4. X4, Gen5. X2 NVMe 2.0 - M.2 Internal SSD, Speed Up to 7,250 MBs, Upgrade Storage for PC-Laptops, HMB Technology and Intelligent Turbowrite (MZ-V9S4T0B/AM)
![SAMSUNG 870 EVO SATA SSD 500GB 2.5” Internal Solid State Drive, Upgrade PC or Laptop Memory and Storage for IT Pros, Creators, Everyday Users, MZ-77E500B/AM [Canada Version]](https://m.media-amazon.com/images/I/911ujeCkGfL._AC_UL960_FMwebp_QL65_.jpg)
SAMSUNG 870 EVO SATA SSD 500GB 2.5” Internal Solid State Drive, Upgrade PC or Laptop Memory and Storage for IT Pros, Creators, Everyday Users, MZ-77E500B/AM [Canada Version]
![SAMSUNG T9 4TB Portable SSD, USB 3.2 Gen. 2x2, Black, Upto 2000MB/s Read Speed - MU-PG4T0B/AM [Canada Version]](https://m.media-amazon.com/images/I/71EESd1deTL._AC_UL960_FMwebp_QL65_.jpg)
SAMSUNG T9 4TB Portable SSD, USB 3.2 Gen. 2x2, Black, Upto 2000MB/s Read Speed - MU-PG4T0B/AM [Canada Version]

UGREEN USB to USB C Adapter & USB C to USB Adapter Combo 4-Pack, 10Gbps Type-C Converter, Car Charger Compatible with MacBook Pro, iPad Mac mini, iPhone 17/16, Galaxy, PC/Laptop, Hard Drive Enclosure

Syntech USB C to USB Adapter Pack of 2 USB C Male to USB3 Female Adapter Compatible with MacBook Pro 2021 iMac iPad Mini 6/Pro MacBook Air 2020 and Other Type C or Thunderbolt 4/3 Devices Space Grey

Elebase USB to USB C Adapter 4 Pack,USBC Female to A Male Car Charger,Type C Converter for iPhone 16 Pro Max,15 14 13 12 11 Plus,Apple Watch iWatch 10 9 8,Airpods,iPad Air Mini 6 7,Samsung Galaxy S25

TP-Link USB to Ethernet Adapter (UE306) - Foldable USB 3.0 to Gigabit Ethernet LAN Laptop Network Adapter, Supports Nintendo Switch, Windows, Linux, Apple MacBook OS 10.11- OS 12, Surface

Apple MFi Certified iPhone Flash Drive, Photo Stick,iPhone Memory Stick 512GB, USB Thumb Drive for Photos Videos Transfer, High Speed Jump Drive Compatible for iPhone/iPad/Android/PC Pink

Vansuny 128GB USB C Flash Drive 2 in 1 OTG USB 3.0 + USB C Memory Stick with Keychain Dual Type C USB Thumb Drive Photo Stick Jump Drive for Smartphone, Computers, MacBook, Tablets, PC

USB Stick 64GB, Aiibe 64GB USB Flash Drive 64GB USB 2.0 Memory Stick Thumb Drive Data Storage Jump Drive for Laptop(64G, Green)

Aiibe 5 Pack 64 GB Flash Drive USB Sticks Thumb Drive 64 GB USB 2.0 Flash Disk Jump Drive Multi Pack USB Stick Pack Zip Drives 64GB with Led Light (5 Colors,64gb)

Seagate Portable 4TB External Hard Drive HDD – USB 3.0 for PC, Mac, Xbox, & PS4 - 1-Year Rescue Service (STGX4000400)

Seagate Game Drive 4TB External Hard Drive Portable HDD - Compatible With PS4 (STGD4000400) blue

Western Digital 4TB My Book Desktop External Hard Drive, USB 3.0, External HDD with Password Protection and Backup Software - WDBBGB0040HBK-NESN

Dell 27 Plus 4K Monitor - S2725QS - 27-inch 4K (3840 x 2160) 120Hz 16:9 Display, IPS Panel, AMD FreeSync Premium, sRGB 99%, Integrated Speakers, 1500:1 Contrast Ratio, Comfortview Plus - Ash White

Dell UltraSharp U2723QE 27" 4K UHD WLED LCD Monitor - 16:9 - Black, Silver EPEAT

USB C Docking Station Dual Monitor for Dell Hp,15-in-1 Laptop Docking Station 3 Monitors USB C Hub with Dual 4K HDMI,8K DP,Button,PD Charging,Ethernet,6 USB A&C,SD/TF, Audio USB-C Multiport Adapter




















