Skip to content
Permalink
master
Switch branches/tags
Go to file
 
 
Cannot retrieve contributors at this time
executable file 14 lines (11 sloc) 278 Bytes
#!/usr/bin/env bash
set -eu
default_branch=$(git default-branch)
if ! [ $# -eq 0 ]; then
git commit --fixup "$1"
else
git --no-pager log $default_branch.. --pretty=format:"%h %s" |
selecta |
awk '{print $1}' |
{ read commit; git commit --fixup $commit; }
fi