Commit GPT is a Visual Studio Code extension that generates commit messages using your GitHub Copilot chat model access, via VS Code's Language Model API. It helps developers create descriptive and meaningful commit messages based on the staged changes in their Git repository.
- Commit Message Generation: Automatically generates commit messages based on the staged changes in your Git repository.
- Copilot Integration: Uses VS Code's Language Model API to generate human-like and context-aware commit messages via your GitHub Copilot access — no separate API key needed.
- Customizable: Lets you choose which Copilot chat model family to use for generation.
- Easy to Use: Simple commands to generate commit messages and select a chat model directly within VS Code.
- Visual Studio Code (version 1.91.0 or higher)
- GitHub Copilot (installed and signed in) — Commit GPT generates messages via VS Code's Language Model API, using whichever Copilot chat model you have access to. No separate API key needed.
- Install Visual Studio Code on your system if you haven't already: Download VS Code.
- Launch VS Code.
- Go to Extensions (or press
Ctrl+Shift+X). - Search for "Commit GPT".
- Click Install to install the extension.
-
(Optional) Choose a chat model:
- Open the Command Palette (
Ctrl+Shift+PorCmd+Shift+Pon Mac). - Type
Commit GPT: Select Chat Modeland press Enter. - Pick which Copilot chat model family to use from the list. If you skip this step, Commit GPT uses whichever Copilot model is available.
- Open the Command Palette (
-
Generate Commit Message:
- Stage your changes in Git.
- Open the Command Palette.
- Type
Commit GPT: Generate Commit Messageand press Enter. - Or click the Commit GPT button (a grey commit node with a blue spark) in the Source Control title bar. The message streams into the commit box as it is written.
- Nothing staged? Commit GPT offers to stage everything and generate in one click.
-
Not quite right? Run
Commit GPT: Regenerate Commit Message with Hint…(also in the Source Control…menu) and say what to change, e.g. "make it shorter" or "mention ABC-123".
commit-gpt.style:conventional(default),gitmoji, orplain.commit-gpt.model: The Copilot chat model family used to generate commit messages. Set this using theCommit GPT: Select Chat Model…command or directly in your VS Code settings. Empty means the first available model.commit-gpt.customPrompt: Your own prompt template. Use{{diff}}where the staged diff should go. Overridesstyle.
- No known issues.
- Initial release of Commit GPT extension.
- If you find any issues or have suggestions for improvement, please report them.
- Contributions are always welcome! Fork the repository and submit a pull request.
This extension is licensed under the MIT License.
Feel free to replace placeholders such as your-repo-url with the appropriate links to your GitHub repository or issue tracker. Additionally, you can add more sections, such as "Acknowledgments," "Support," or "Author," to provide further information about your extension.
