3 if [ "$#" -lt 1 ]; then
4 printf "Usage: %s <commit range>\n", "$0" 1>&2
8 commits=$(git rev-list --no-merges "$@")
9 if [ -z "$commits" ]; then
31 printf "Commit%s\n\n" "$s"
32 git log --no-walk --pretty='format: %h ("%s")' "$@"
33 printf "\n%s missing a Signed-off-by from %s %s%s.\n" "$is" "$its" "$t" "$s"
38 ae=$(git log -1 --format='<%ae>%n<%aE>%n %an %n %aN ' "$c")
39 ce=$(git log -1 --format='<%ce>%n<%cE>%n %cn %n %cN ' "$c")
40 sob=$(git log -1 --format='%b' "$c" | grep -i '^[[:space:]]*Signed-off-by:')
44 grep -i -F -q "$ae" <<<"$sob" ||
46 grep -i -F -q "$ce" <<<"$sob" ||
48 "$am" && author_missing+=" $c"
49 "$cm" && committer_missing+=" $c"
52 if [ "$author_missing" ]; then
53 print_commits "author" $author_missing
55 if [ "$committer_missing" ]; then
56 print_commits "committer" $committer_missing