Change gfix abbrev to rebase to default branch
This commit is contained in:
parent
9b4da12f6a
commit
e319165063
1 changed files with 3 additions and 3 deletions
|
|
@ -95,16 +95,16 @@
|
|||
end
|
||||
'';
|
||||
};
|
||||
git_pick-commit_merge-base_origin_master = {
|
||||
git_pick-commit_merge-base_origin = {
|
||||
description = "fuzzy find a commit hash";
|
||||
body = ''
|
||||
git log --oneline (git merge-base HEAD origin/master)..HEAD | ${pkgs.fzf}/bin/fzf --preview='git show (echo {} | cut -d" " -f 1)' --preview-window=top:75% | cut -d" " -f 1
|
||||
git log --oneline refs/remotes/origin/HEAD..HEAD | ${pkgs.fzf}/bin/fzf --preview='git show (echo {} | cut -d" " -f 1)' --preview-window=top:75% | cut -d" " -f 1
|
||||
'';
|
||||
};
|
||||
gfix = {
|
||||
description = "git commit --fixup with fuzzy find commmit picker";
|
||||
body = ''
|
||||
set commit (git_pick-commit_merge-base_origin_master)
|
||||
set commit (git_pick-commit_merge-base_origin)
|
||||
commandline "git commit --fixup=$commit"
|
||||
'';
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue