Created
August 29, 2012 20:45
-
-
Save grodzik/3518700 to your computer and use it in GitHub Desktop.
git publish alias
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
publish = "!sh -c 'if [ -n \"$1\" ]; then CURRENT=$1; else CURRENT=$(git symbolic-ref HEAD); fi; CURRENT=${CURRENT##*refs/heads/}; echo $CURRENT; git push origin $CURRENT; git config branch.${CURRENT}.merge refs/heads/${CURRENT}; git config branch.${CURRENT}.remote origin;'" -- |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment