Skip to content

Commit

Permalink
git: add a coauth alias
Browse files Browse the repository at this point in the history
  • Loading branch information
andrew-nowak committed Nov 27, 2023
1 parent a9610cc commit 372de56
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions .gitconfig
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
branches = branch -a

co = checkout
coauth = !"f() { args=(); names=\"$(git shortlog --summary --numbered --email --all | rg -S '^\\s+[0-9]+\\s+' -r 'Co-authored-by: ')\" trail=\"$(fzf <<< \"$names\")\"; while [[ \"$?\" = 0 ]]; do args+=( --trailer \"$trail\" ) ; trail=\"$(fzf <<< \"$names\")\"; done; git commit \"${args[@]}\" \"$@\"; }; f"

d = diff
da = diff HEAD
Expand Down

0 comments on commit 372de56

Please sign in to comment.