Created
May 1, 2009 15:44
-
-
Save dcparker/105099 to your computer and use it in GitHub Desktop.
Clone a git repo, checking out a specific branch.
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
# First, mkdir name & chdir name | |
git init | |
git remote add -t $2 origin $1 | |
git fetch | |
git checkout --track -b $2 origin/$2 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment