-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathKO
More file actions
executable file
·32 lines (29 loc) · 724 Bytes
/
KO
File metadata and controls
executable file
·32 lines (29 loc) · 724 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#!/bin/sh
#
# Not for general consumption; a script I used to make sure
# I do not accidentally push a rewound master to public.
no_fetch= ko=ko
while :
do
case "$#,$1" in
0,*) break ;;
*,--no-fetch) no_fetch=t; shift ;;
*,--*) echo >&2 "unknown option $1"; exit 1 ;;
*) ko=$1; shift ;;
esac
done
if test -z "$no_fetch"
then
git fetch "$ko"
fi
mb=$(git merge-base $ko/master master)
h=$(git rev-parse $mb $ko/master | sort -u | wc -l)
if test "$h" != 1
then
echo "OOOOOPPPPPPPPPPPPPPSSS! master is not $ko/master fast forward."
exit 1
fi
git show-branch --topo-order $ko/master master
git show-branch --topo-order $ko/maint maint
git show-branch --topo-order $ko/next next
git show-branch --topo-order $ko/pu pu