forked from keis/git-fixup
-
Notifications
You must be signed in to change notification settings - Fork 0
cgiuffr/git-fixup
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
git-fixup ========= Fighting the copy-paste element of your rebase workflow. `git fixup <ref>` is simply an alias for `git commit --fixup <ref>`. That's just a convenience feature that can be also be used to trigger tab completion. The magic is in plain `git fixup` without any arguments. It finds which lines/files you have changed, uses git blame/log to find the most recent commits that touched those lines/files, and displays a list for you to pick from. This is a convenient alternative to manually searching through the commit log and copy-pasting the commit hash. Install ------- make install make install-zsh -or- Copy the program and completion script into your $PATH and $fpath respectively. Usage ----- For this tool to make any sense you should enable the rebase.autosquash setting in the git config. .. change stuff and discover something that calls for a fixup! $ git add -p select the changes that should be part of the fixup $ git fixup outputs a list of commits that the staged changes are likely a fixup of $ git fixup <ref> create a fixup!-commit of the given ref, if you have installed the zsh script you can cycle through the list of fixup candidates with tab completion. $ git rebase -i ... commit rebased into the selected commit as a fixup Tab completion -------------- The suggestions for the tab completion is the suggested fixup bases as generated by running the tool without any arguments. To be able to tab complete the command itself add a line like this to your zsh configuration:: zstyle ':completion:*:*:git:*' user-commands fixup:'Create a fixup commit'
About
Fighting the copy-paste element of your rebase workflow.
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published
Languages
- Shell 100.0%