{"id":30141183,"url":"https://github.com/njengah/gemini-cli-cheat-sheet","last_synced_at":"2025-08-11T04:35:06.519Z","repository":{"id":303125316,"uuid":"1014489852","full_name":"Njengah/gemini-cli-cheat-sheet","owner":"Njengah","description":"A comprehensive reference guide for Google's Gemini CLI commands. This cheatsheet provides quick command lookup model switching examples, and practical usage patterns for developers at all levels.","archived":false,"fork":false,"pushed_at":"2025-07-08T20:57:21.000Z","size":7707,"stargazers_count":36,"open_issues_count":0,"forks_count":4,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-08-02T01:24:45.969Z","etag":null,"topics":["gemini","gemini-api","gemini-cli","gemini-pro","google"],"latest_commit_sha":null,"homepage":"https://medium.com/@joe.njenga","language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Njengah.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-07-05T20:36:38.000Z","updated_at":"2025-07-31T10:59:25.000Z","dependencies_parsed_at":"2025-07-05T21:33:57.971Z","dependency_job_id":"90a7e759-0213-4282-a34c-9656d76ce5d6","html_url":"https://github.com/Njengah/gemini-cli-cheat-sheet","commit_stats":null,"previous_names":["njengah/gemini-cli-cheat-sheet"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Njengah/gemini-cli-cheat-sheet","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Njengah%2Fgemini-cli-cheat-sheet","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Njengah%2Fgemini-cli-cheat-sheet/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Njengah%2Fgemini-cli-cheat-sheet/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Njengah%2Fgemini-cli-cheat-sheet/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Njengah","download_url":"https://codeload.github.com/Njengah/gemini-cli-cheat-sheet/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Njengah%2Fgemini-cli-cheat-sheet/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":269831971,"owners_count":24482300,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-11T02:00:10.019Z","response_time":75,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["gemini","gemini-api","gemini-cli","gemini-pro","google"],"created_at":"2025-08-11T04:35:04.146Z","updated_at":"2025-08-11T04:35:06.504Z","avatar_url":"https://github.com/Njengah.png","language":null,"readme":"# Gemini CLI Cheatsheet\n\n![Alt text](images/gemini_cli_cheat_sheet.png)\n\n\u003e **Your complete guide to mastering Gemini CLI - from zero to hero in minutes!**\n\nAfter testing Gemini CLI I've developed this comprehensive cheat sheet that will take you from basic to advanced user without wasting time. Whether you're completely new to Gemini CLI or looking to master advanced features, this guide has you covered.\n\n## Quick Start\n\n```bash\n# Install globally\nnpm install -g @google/gemini-cli\n\n# Or run without installing\nnpx @google/gemini-cli\n\n# Launch interactive CLI\ngemini\n```\n\n## 📚 Table of Contents\n\n- [🟢 Level 1: Basic Commands](#-level-1-basic-commands)\n- [🟡 Level 2: Intermediate Commands](#-level-2-intermediate-commands)\n- [🟠 Level 3: Advanced Commands](#-level-3-advanced-commands)\n- [🔴 Level 4: Expert Commands](#-level-4-expert-commands)\n- [🔵 Level 5: Power User Commands](#-level-5-power-user-commands)\n- [🟣 Level 6: Master Commands](#-level-6-master-commands)\n- [🤝 Contributing](#-contributing)\n- [📄 License](#-license)\n\n---\n\n## 🟢 Level 1: Basic Commands\n\nEssential commands to get started\n\n### Installation \u0026 Getting Started\n\n```bash\nnpm install -g @google/gemini-cli     # Install globally\nnpx @google/gemini-cli                # Run without installing\ngemini                                # Launch interactive CLI\ngemini --version                      # Check version\n```\n\n### Basic Navigation\n\n```bash\n/about                    # Check version\n/help                     # Show available commands\n/tools                    # List available tools\n/clear                    # Clear current conversation\n/quit                     # Exit CLI (or Ctrl+C)\n```\n\n### Basic File Operations\n\n```bash\nReadFolder                # Read folder contents\nReadFile                  # Read single file\nReadManyFiles             # Read multiple files\n```\n\n### File System Operations - Natural Language\n\n```bash\n# Using natural language\n\"List files in current directory\"\n\"Show me the contents of package.json\"\n\"Find all HTML files in this project\"\n```\n\n### Basic Tools\n\n```bash\n/tools                     # List available tools\n/tools desc                # Show tool descriptions\n/tools nodesc              # Hide tool descriptions\n```\n\n### Basic Configuration\n\n```bash\n/theme                     # Change visual theme\n/auth                      # Change authentication method\n/editor                    # Select supported editors\n```\n\n### Basic Shell Command\n\n```bash\nshell ls                    # List directory contents\n```\n\n### Keyboard Shortcuts\n\n```bash\nEnter                       # Send message\nEsc                         # Cancel operation\nCtrl+L                      # Clear screen\nCtrl+C x2                   # Exit CLI / Quit application\nCtrl+T                      # Toggle tool descriptions\nUp/Down                     # Cycle through prompt history || Tools\nAlt+Left/Right              # Jump through words\n```\n\n### Troubleshooting \u0026 Tips\n\n```bash\n/privacy                   # View privacy settings\n/bug                       # Submit bug report\n/docs                      # Open documentation\n/about                     # Check version info\n```\n\n---\n\n## 🟡 Level 2: Intermediate Commands\n\nFile management and basic customization\n\n### File Management\n\n```bash\n/tools \nread_folder \u003cdirectory\u003e              # Read entire folder\n@src/my_project/                     # Read entire project directory\n@path/to/file.txt                    # Read specific file\n@My\\ Documents/file.txt              # Handle spaces in paths\n```\n\n### Conversation Management\n\n```bash\n/chat save \u003ctag\u003e                     # Save current conversation\n/chat resume \u003ctag\u003e                   # Resume saved conversation\n/chat list                           # List saved conversations\n/compress                            # Compress chat context to summary\n```\n\n### Model Configuration\n\n```bash\n--model                             # Show current model\n--model gemini-1.5-flash            # Switch to Flash (fastest)\n--model gemini-1.5-pro              # Switch to Pro (most capable)\n--model gemini-1.5-pro-002          # Switch to latest Pro version\n```\n\n### Memory Management\n\n```bash\n/memory show                        # Show current memory context\n/memory add \u003ctext\u003e                  # Add text to memory\n/memory refresh                     # Reload GEMINI.md files\n```\n\n---\n\n## 🟠 Level 3: Advanced Commands\n\nConfiguration, context, and power features\n\n### Execution Methods\n\n```bash\ngemini -p \"your prompt here\"         # Direct prompt execution\ngemini -y                            # Auto-confirm all prompts (YOLO mode)\ngemini --sandbox                     # Run in sandbox mode\ngemini --checkpointing               # Enable checkpointing\n```\n\n### Statistics \u0026 Monitoring\n\n```bash\n/stats                               # Show session statistics\n/stats model                         # Show model usage stats\n/stats tools                         # Show tool usage stats\n```\n\n### Shell Integration\n\n```bash\n!\u003cshell_command\u003e                     # Execute shell command\n!ls -la                              # Example: list files\n!git status                          # Example: git status\n!                                    # Toggle shell mode\n```\n\n### Context Management\n\n```bash\n@\u003cpath_to_file\u003e                     # Include file content in prompt\n@\u003cdirectory\u003e                        # Include directory content\n@README.md                          # Example: include README\n@src/myFile.ts                      # Add specific file to context\n@folder/                            # Add entire folder to context\n```\n\n---\n\n## 🔴 Level 4: Expert Commands\n\nMCP servers, automation, and advanced integrations\n\n### MCP Server Management\n\n```bash\n/mcp list                 # List available MCP servers\n/mcp desc                 # Show detailed MCP descriptions\n/mcp nodesc               # Hide MCP descriptions\n/mcp schema               # Show full JSON schema\n```\n\n### Advanced Execution\n\n```bash\nnpx @google/gemini-cli                          # Run latest version\nnpx https://github.com/google-gemini/gemini-cli  # Run from GitHub\n```\n\n### Sandbox Configuration\n\n```bash\ngemini -s                           # Enable sandboxing (short flag)\nexport GEMINI_SANDBOX=true          # Environment variable\nexport GEMINI_SANDBOX=docker        # Specify Docker\nexport GEMINI_SANDBOX=podman        # Specify Podman\nexport GEMINI_SANDBOX=sandbox-exec  # Specify sandbox-exec (macOS)\n```\n\n### Advanced File Operations\n\n```bash\n# Git-aware filtering automatically excludes:\n# node_modules/, dist/, .env, .git/\n# Can be configured via fileFiltering settings\n```\n\n---\n\n## 🔵 Level 5: Power User Commands\n\nAdvanced workflows and integrations\n\n### Container-based Execution\n\n```bash\ndocker run --rm -it us-docker.pkg.dev/gemini-code-dev/gemini-cli/sandbox:0.1.1\ngemini --sandbox -y -p \"your prompt here\"\n```\n\n### Development Mode\n\n```bash\nnpm run start                        # Hot-reloading development\nnpm link packages/cli                # Link local package globally\n```\n\n### Environment Variables\n\n```bash\nexport SEATBELT_PROFILE=permissive-open     # macOS sandbox profile\nexport SEATBELT_PROFILE=restrictive-closed  # Strict macOS sandbox\nexport SANDBOX_SET_UID_GID=true             # Force host UID/GID\nexport DEBUG=1                              # Enable debug mode\n```\n\n### Checkpointing \u0026 Restore\n\n```bash\n/restore                             # List available checkpoints\n/restore \u003ccheckpoint_file\u003e           # Restore specific checkpoint\n/restore 2025-06-22T10-00-00_000Z-my-file.txt-write_file\n```\n\n---\n\n## 🟣 Level 6: Master Commands\n\nAdvanced automation and custom workflows\n\n### Bug Reporting \u0026 Issues\n\n```bash\n/bug \"Issue description\"             # File GitHub issue\n                                     # Customizable via bugCommand setting\n```\n\n### Extension Management\n\n```bash\n# Extensions loaded from:\n# \u003cworkspace\u003e/.gemini/extensions\n# \u003chome\u003e/.gemini/extensions\n```\n\n### Advanced Settings (settings.json)\n\n```json\n{\n  \"sandbox\": \"docker\",\n  \"checkpointing\": { \"enabled\": true },\n  \"bugCommand\": \"custom command\",\n  \"mcpServers\": {\n    \"my-server\": {\n      \"command\": \"node my-server.js\"\n    }\n  }\n}\n```\n\n---\n\n## 🤝 Contributing\n\nWe welcome contributions! Please see [CONTRIBUTING.md](CONTRIBUTING.md) for guidelines.\n\n### Ways to Contribute\n\n- 🐛 Report bugs or issues\n- 📝 Improve documentation\n- ✨ Add new commands or examples\n- 🔧 Test commands and report results\n\n## 📄 License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n\n## ⭐ Support\n\nIf this cheatsheet helped you, please give it a star! It helps others discover this resource.\n\n---\n\n## 📞 Connect\n\n- **Contact**: [Email](mail.njengah@gmail.com)\n\n---\n\nLast updated: July 2025\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnjengah%2Fgemini-cli-cheat-sheet","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnjengah%2Fgemini-cli-cheat-sheet","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnjengah%2Fgemini-cli-cheat-sheet/lists"}