CheckPush: older integration branches should be subset of newer ones

todo
Junio C Hamano 2011-07-31 17:08:33 -07:00
parent fa8727c618
commit 9392cbd42b
1 changed files with 32 additions and 0 deletions

32
CheckPush Executable file
View File

@ -0,0 +1,32 @@
#!/bin/sh

for range in $(
prev_branch=
{
git for-each-ref --format='%(refname)' refs/heads/maint-* |
sed -e 's|^refs/heads/||'
cat <<-EOF
maint
master
next
EOF
} |
while read branch
do
if test -n "$prev_branch"
then
echo "$branch..$prev_branch"
fi
prev_branch=$branch
done
) pu..jch
do
lg=$(git log --oneline "$range")
if test -n "$lg"
then
echo "*** $range ***"
echo "$lg"
fi
done

git diff --stat next jch