lazygit
lazygit copied to clipboard
Autocomplete/suggest git commit message based on commit history
Is your feature request related to a problem? Please describe. Sometimes we (at least me) just copy messages from previous commits. For example: "Bump version...", Update X to version Y.
Describe the solution you'd like
Suggest a message based on the history when we are typing, like in k9s:
I am not thinking about some highly intelligent, super fancy AI powered autocomplete engine, just a simple regex which matches from the start.
What do you think about something like this?
I would love to see that feature implemented.
Also, it would be nice to have autocompletion of Conventional Commits like feat, fix, refactor etc. as well as scope for them (based on file/directory names of staged files for example).
using the https://github.com/lintingzhen/commitizen-go wizard would be awesome here. Use lazygit and commitizen in split terminal right now.
https://github.com/Nutlope/aicommits
Would be cool if we could use this
Came here to ask for aicommits support, was sure that no one asked before, but searched anyway :) I would love this support also, but in the meantime i found a workaround:
- go to your repo, do
aic hook install - open lazygit and commit via
C-> this will open the git commit editor, which is defined to fire up aic
Just a bug related to my workaound, if you don't issue the lazygit from the root repo path, i get:
2023/04/05 15:30:32 An error occurred! Please create an issue at: https://github.com/jesseduffield/lazygit/issues
*errors.errorString repository does not exist
/private/tmp/lazygit-20230201-69813-1wzwylz/lazygit-0.37.0/pkg/app/app.go:54 (0x10084acf4)
/private/tmp/lazygit-20230201-69813-1wzwylz/lazygit-0.37.0/pkg/app/entry_point.go:146 (0x10084c6d0)
/private/tmp/lazygit-20230201-69813-1wzwylz/lazygit-0.37.0/main.go:23 (0x10084e628)
/opt/homebrew/Cellar/go/1.19.5/libexec/src/runtime/proc.go:250 (0x10029bcec)
/opt/homebrew/Cellar/go/1.19.5/libexec/src/runtime/asm_arm64.s:1172 (0x1002ca344)
Just a bug related to my workaound, if you don't issue the lazygit from the root repo path, i get:
2023/04/05 15:30:32 An error occurred! Please create an issue at: https://github.com/jesseduffield/lazygit/issues *errors.errorString repository does not exist /private/tmp/lazygit-20230201-69813-1wzwylz/lazygit-0.37.0/pkg/app/app.go:54 (0x10084acf4) /private/tmp/lazygit-20230201-69813-1wzwylz/lazygit-0.37.0/pkg/app/entry_point.go:146 (0x10084c6d0) /private/tmp/lazygit-20230201-69813-1wzwylz/lazygit-0.37.0/main.go:23 (0x10084e628) /opt/homebrew/Cellar/go/1.19.5/libexec/src/runtime/proc.go:250 (0x10029bcec) /opt/homebrew/Cellar/go/1.19.5/libexec/src/runtime/asm_arm64.s:1172 (0x1002ca344)
Has this been solved?
It would be great if it was possible to get an AI commit preview for the title and the same for the description, after the title is written and the description field entered.
Would also like to see this work in a zsh fashion for commit and branch names. ie pressing tab or -> to autofill up to a certain point in the message based on previous commits/branches
++ Would love to see this feature, we can start with something as basic as auto suggest title based on the path of the file being changed.
@WladyX did you do anything else to get the hooks workings within lazygit?
I installed it, setup my API key, installed the hook within my repo and can see it within .git/hooks but when I stage a file and press c it doesn't trigger it, I can manually trigger it from the cli but not within lazygit
edit: lazygit it opened from the repo root
nothing else, but it must be capital c, C, not c