5 echo "$0: <commit id> [<top tag> [<linus branch>]]" 1>&2
8 commit=$(git rev-parse --verify "$commit")
10 echo "No such commit" 1>&2
15 [ "$top" ] || top=HEAD
16 tcommit=$(git rev-parse --verify "$top")
18 echo "Bad top tag" 1>&2
23 [ "$linus" ] || linus=origin/master
24 lcommit=$(git rev-parse --verify "$linus")
26 echo "Bad linus branch" 1>&2
30 base=$(git merge-base "$linus" "$top")
32 git log --first-parent --reverse --pretty='format:%H %P' "$base".."$top" |
35 [ "$p1" = "$commit" ] && {
36 git show -s --pretty="format:Commit: %H%nAuthor: %aN <%aE>%nAuthorDate: %ad%nCommitter: %cN <%cE>%nCommitterDate: %cd%nSubject: %s" $p1
41 git rev-list $base..$p2 | grep -q "$commit" || continue
42 git show -s --pretty="format:Commit: %H%nAuthor: %aN <%aE>%nAuthorDate: %ad%nCommitter: %cN <%cE>%nCommitterDate: %cd%nSubject: %s" $m