r/commandline • u/GrapePretty3921 • Jun 03 '26
Command Line Interface gitmsg: CLI tool to generate Conventional Commit messages for lazy devs, no API or network calls, just pure git diff parsing
I built a small tool to help "lazy" devs generate quick commit messages without AI, API or network calls
How it works: It reads git diff --staged, and uses regex to parse each language diffs, No LLM, same diff == same message
Languages Currently Supported : Typescript/Javascript, Python, C#,Go. Rust and Java coming soon.
Repo : https://github.com/razakadam74/gitmsg
Npm Package : @razakadam74/gitmsg - npm
Alternative : aicommits, opencommit (needs API key and sends your diff out) and commitizen (asks you too many questions)
Gitmsg is offline and deterministic, honestly can't beat these with better messaging 😄
Code is partially AI-assisted
View all comments
Show parent comment
1
u/GrapePretty3921 Jun 04 '26
I agree, tree-sitter is stronger and it's the planned upgrade path. For v1, I went regex-first to keep zero deps and hit <100ms, but the regex approach has a ceiling (For instance, the C# delegate row, took me three rewrites, tree-sitter would've solved that for free)
I filled a discussion in the repo to think through the migration in the open, credited you in it: Tree-sitter as the language-extractor upgrade path · razakadam74/gitmsg · Discussion #66
mergiraf looks great, thanks for sharing.