ficommitgen-vscode is a Visual Studio Code extension that generates commit messages automatically using Google Gemini AI (currently) based on changes (git diff) in your Git repository.
✨ Features
🔍 Automatically reads git diff and git log for more accurate context
🧠 Generates commit messages using AI, following the Conventional Commits specification
📋 Automatically inserts the generated message into the Source Control input box
🧩 Integrated with VS Code's built-in Git UI (button in the Source Control title)
🛡️ API token is securely stored using VS Code's SecretStorage (not settings.json)
🛠️ Requirements
VS Code version 1.101.0 or later
A Git repository must be initialized (git init)
A Google Gemini API token (you'll be prompted on first use)
🚀 Usage
Generate Commit Message
You can generate a commit message in two ways:
Open the Source Control panel
Click the "Generate Commit" button (sparkle ✨ icon) in the Source Control title
OR
Open the Command Palette (Ctrl+Shift+P on Windows/Linux, Cmd+Shift+P on macOS, or F1)
Select "Ficommitgen: Generate Commit"
Note: If you have staged changes, it will try to generate commit message based on staged changes first. If not, it will generate commit message based on unstaged changes.
Set Token
To reset or update your API token:
Open the Command Palette
Select "Ficommitgen: Set Token"
⚙️ Extension Settings
There are currently no settings configurable via settings.json.
🐛 Known Issues
If your project is not initialized as a Git repository, the extension will not work.
If the Gemini API token is missing, incorrect, or rate-limited, commit generation will fail.