Created

Embed URL

HTTPS clone URL

SSH clone URL

You can clone with HTTPS or SSH.

Download Gist

change merge script

View change-merged
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 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58
#!/bin/sh
 
touch $HOME/review_site/logs/hook.log
exec >>$HOME/review_site/logs/hook.log 2>&1
 
while [ $# -gt 0 ]
do
arg=$1
shift
 
case "$arg" in
--change)
change=$1
;;
--change-url)
change_url=$1
;;
--project)
project=$1
;;
--branch)
branch=$1
;;
--submitter)
submitter=$1
;;
--commit)
commit=$1
;;
*)
echo "Unexpected arg: $arg"
exit 1
;;
esac
shift
done
 
case $project in
spymemcached)
repo="git@github.com:dustin/java-memcached-client.git"
;;
*)
repo="git@github.com:membase/$project.git"
;;
esac
 
echo "date: `date`"
echo "change: $change"
echo "change_url: $change_url"
echo "project: $project"
echo "branch: $branch"
echo "submitter: $submitter"
echo "commit: $commit"
echo "repo: $repo"
 
git push $repo $branch:refs/heads/$branch
git fetch --tags $repo
git gc --auto
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.