Created
November 4, 2011 08:28
-
-
Save kunitoo/1338920 to your computer and use it in GitHub Desktop.
local,remoteにブランチを作成して移動する
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
#/bin/sh | |
if [ $# -ne 1 ]; then | |
echo "sh create_branch.sh 'branch_name'" 1>&2 | |
exit 1 | |
fi | |
git branch $1 | |
git checkout $1 | |
git push origin $1 | |
git config --add branch.$1.remote origin | |
git config --add branch.$1.merge refs/heads/$1 | |
exit 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment