git/pushall
2012-12-06 13:48:43 -08:00

34 lines
536 B
Bash
Executable File

#!/bin/sh
case "$#" in
0)
tagged=
for branch in maint master
do
t=$(git describe --exact-match $branch 2>/dev/null) &&
tagged="$tagged$t "
done
if test -n "$tagged"
then
"$0" $tagged
fi
esac
for remote in ko repo gph github2 sfjp sf.net
do
printf "%s: " "$remote"
git push "$remote" "$@" || exit $?
done
case "$#,$*" in
0,* | 1,-n)
printf "github mirror: "
git push github "$@" || exit $?
for topic in htmldocs manpages
do
printf "%s: " "$topic"
( cd ../git-$topic.git && git push "$@") || exit
done
;;
esac