-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature request: add option to fixup selected commit #96
Comments
Hi, I'm unsure on how to do that. GitLG internally just uses shell-commands that are valid on both Windows and Unix systems. Do you have any idea what the command would look like? Sounds like history rewriting stuff. There are two similar commands in place already. This one is for editing the commit message: git diff-index --quiet HEAD && git merge-base --is-ancestor "{COMMIT_HASH}" HEAD && git commit --allow-empty --only -m "amend! {COMMIT_HASH}\n\n{NEW_COMMIT_MESSAGE}" && git -c sequence.editor=: rebase -i --autosquash "{COMMIT_HASH}^" But apart from that, is fixuping the staged changes into an existing commit an action common enough to warrant a place in the default commit actions (which you can augment yourself)? Also the difference between squash and fixup in this context seems to only be regarding the commit message (??). For message editing, there's already said other command so I wouldn't worry about that, we're in rare use case territory already anyway. So yeah I guess we can do this but I definitely need some sample commands and guidance here. |
Thanks for the response! A command might look like Admittedly, I'm afraid that fixup commits for many are an advanced topic (but in my personal opinion, they shouldn't! and having nice integration tools like this might help in that regard). I know that I would use it for sure! :) |
I'd like to be able to right-click a commit in the graph view and be able to create a fixup commit for that commit based on the currently staged changes.
The text was updated successfully, but these errors were encountered: