merge master into staging and staging into testing
#!/bin/sh
git diff --quiet --exit-code
if [ $? -ne 0 ]; then
echo "Cannot run grrr if you have uncommited changes"
exit -1;
fi
current_branch=`git rev-parse --abbrev-ref HEAD`
if [ "$current_branch" == "HEAD" ]; then
echo "Cannot run grrrr if you're not on a branch"
exit -1;
fi
git checkout master && git pull --ff-only && git checkout staging && git pull --ff-only && git merge master && git push && git checkout testing && git pull --ff-only && git merge staging && git push
git checkout "$current_branch"