Help Gemini CLI create, build, test, and run Flutter apps.
- Status: Experimental - This is an experimental project. Features and commands may change drastically. We welcome your feedback!
- 🚀 Project Bootstrapping: Create new Flutter projects from scratch with built-in best practices, including linters, documentation, and design planning.
- 🔧 Guided Modifications: Execute complex modification tasks with automated planning, git branch management, and step-by-step implementation guides for your approval.
- ✅ Automated Pre-Commit Checks: Automatically format, analyze, and test your code before committing to maintain codebase quality.
- ✍️ Smart Commit Messaging: Generate descriptive, conventional commit messages based on your staged changes.
- 🧠 Context Priming: Initializes Gemini with specific rules and context for Dart and Flutter, ensuring high-quality, idiomatic code generation.
- Gemini CLI 0.4.0+ installed and configured.
- Flutter & Dart SDK installed on your system.
- Git installed and available in your PATH.
Use the gemini extensions install command to install directly from the source repository:
gemini extensions install https://github.com/gemini-cli-extensions/flutter.git --auto-updateThe --auto-update is optional: if specified, it will update to new versions as they are released.
You can manage the extension with the following commands:
# Update to the latest version
gemini extensions update flutter
# Uninstall the extension
gemini extensions uninstall flutterThe new commands will be available in new Gemini CLI sessions. The following commands will be available (with or without the flutter: prefix):
/create-app- Guides you through bootstrapping a new Flutter project with best practices./create-package- Guides you through bootstrapping a new Dart package with best practices./modify- Manages a structured modification session with automated planning./commit- Automates pre-commit checks and generates a descriptive commit message.
This extension also installs an MCP server (flutter_launcher) that provides tools for starting, stopping, and interacting with Flutter applications. This server is started automatically, and the following tools are made available:
launch_app: Launches a Flutter application on a specified device.stop_app: Stops a running Flutter application.list_devices: Lists all available devices that can run Flutter applications.get_app_logs: Retrieves the logs from a running Flutter application.list_running_apps: Lists all Flutter applications currently running that were started by this extension.
This extension provides powerful commands to automate key phases of the development lifecycle.
Initiates a guided process to bootstrap a new Flutter application, ensuring your project starts with a solid foundation.
Process:
- Asks for the package's purpose, details, and desired location on your filesystem.
- Creates a new Flutter project with recommended settings and linter rules.
- Generates starter
pubspec.yaml,README.md, andCHANGELOG.mdfiles. - Produces a
DESIGN.mdandIMPLEMENTATION.mdfor your review and approval before any code is written.
/create-app I want to create a trip planning appStarts a structured session to modify existing code. It helps you plan and execute changes safely and efficiently.
Process:
- Asks for your high-level modification goals and what you want to accomplish.
- Offers to create a new
gitbranch for the modification work, isolating changes. - Generates a
MODIFICATION_DESIGN.mddesign document detailing the proposed changes. - Creates a phased
MODIFICATION_IMPLEMENTATION.mdplan for your review and approval.
/modifyPrepares your staged git changes for a clean, high-quality commit. It acts as an automated pre-commit hook and message generator.
Process:
- Runs
dart fixanddart formatto clean and format your code. - Executes the Dart analyzer to check for static analysis issues.
- Runs your project's test suite to ensure all tests are passing.
- Generates a descriptive commit message based on the staged changes for you to review, edit, and approve.
/commitThis extension enforces a specific set of coding standards to ensure consistency and quality. These rules are defined in the extension's repository:
flutter.md: Contains rules and best practices for writing Dart and Flutter code. These rules are opinionated, and we encourage you to review them to ensure they align with your style.override: Contains important, high-priority rules that are appended to the end of all prompts to ensure they have the most weight.
-
"Command not recognized": Ensure the extension is installed correctly and you have restarted the Gemini CLI. Verify the installation with
gemini extensions list. -
"Gemini CLI version error": This extension requires Gemini CLI version 0.4.0 or greater. Check your version with
gemini --versionand update if necessary.
If you have feedback, suggestions, or run into issues, please file an issue on GitHub.
Contributions are welcome! Please see our CONTRIBUTING.md guide for more details on how to get started.