AI generated commit messages

AI commits
AI commits © BechBox
Published on 13th November, 2022 by Mikkel Bech

Commit messages can be tedious to come up with and I found a better way (for me at least) to do it, so here's how I do git commits by just hitting CMD-enter in VS Code. AI generates the commit message and to be frank, it does a better job than me at it

1. Install auto-commit with:

1curl -fsSL | sh -

2. add OpenAI API key to .zshrc (or whatever terminal you're using)


3. create a file called and make sure it's location is in your path

1git add . && \
2auto-commit && \
3git push

(if you want to include deletes in your commits as well use git add -A instead of git add .)

4. Use the "Command Runner" extension in Visual Studio Code" and add this shortcut to preference > keyboard shortcuts:

2    "key": "cmd+enter",
3    "label": "generate commit and push",
4    "command": "",
5    "args": {"command": "sh"},
6    "when": "editorTextFocus"

5. Make some changes to your code and hit CMD+enter. Auto-commit will make a suggestion for the commit message and if you're satisfied just hit Y

Mikkel Bech
Mikkel Bech

I'm a Designer, Developer, Photographer, 3D Generalist, Musician kind of guy

Read more on the About page