| Crates.io | aicommit-rs |
| lib.rs | aicommit-rs |
| version | 0.0.9 |
| created_at | 2025-06-22 20:11:38.672438+00 |
| updated_at | 2025-12-10 14:21:14.445668+00 |
| description | Small CLI AI git commit generator that works with any OpenAI compatible enpoint |
| homepage | |
| repository | |
| max_upload_size | |
| id | 1721895 |
| size | 89,316 |
Using Google Gemini to generate git comments.
Read examples/aicommit-template to understand what exactly is generated.
Clone the repository and build the project:
cargo build --path .
Add ~/.cargo/bin/ into your PATH.
You can download pre-built binaries in releases section.
If you use mise, add following lines to your ~/.config/mise/config.toml:
[tools]
"ubi:your_github_name/aicommit-rs" = "v0.0.8"
Copy aicommit.toml and aicommit-template into your home directory:
cp examples/aicommit.toml ~/.aicommit.toml
cp examples/aicommit-template ~/.aicommit-template
Replace ~/.aicommit.toml with your own configuration file.
openai_api_key = ""
openai_api_url = "https://api.groq.com/openai/v1"
model_name = "llama-3.3-70b-versatile"
Or through environment variables:
OPENAI_API_KEY=your-api-key aicommit-rs
Follow instructions to get your API key from Google Gemini
Read docs/usage.md for more information.
Add following as a menu custom command in your ~/.config/lazygit/config.yml:
customCommands:
- key: "<c-a>" # Ctrl + a
description: "pick AI commit"
command: 'git commit -m "{{.Form.Msg}}"'
context: "files"
prompts:
- type: "menuFromCommand"
title: "ai Commits"
key: "Msg"
command: "aicommit-rs"
filter: '^(?P<number>\d+)\.\s(?P<message>.+)$'
valueFormat: "{{ .message }}"
labelFormat: "{{ .number }}: {{ .message | green }}"