Created
April 21, 2016 15:15
-
-
Save delputnam/3f1f848eecaaa2f694c5812346e0d44a to your computer and use it in GitHub Desktop.
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
mkdir repo_name | |
cd repo_name | |
git init | |
git remote add origin git@github.com:username/repo_name.git | |
git config core.sparsecheckout true | |
echo "dir_to_clone/*" >> .git/info/sparse-checkout | |
git pull origin master |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
If you don't need all the history, add --depth=1 to pull only the latest commit.