Created
May 11, 2013 12:56
Revisions
-
sumardi created this gist
May 11, 2013 .There are no files selected for viewing
This file contains hidden or 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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,18 @@ # New repository mkdir <repo> && cd <repo> git init git remote add –f <name> <url> git config core.sparsecheckout true echo some/dir/ >> .git/info/sparse-checkout echo another/sub/tree >> .git/info/sparse-checkout git pull <remote> <branch> # Existing repository git config core.sparsecheckout true echo some/dir/ >> .git/info/sparse-checkout echo another/sub/tree >> .git/info/sparse-checkout git read-tree -mu HEAD # If you later decide to change which directories you would like checked out, # simply edit the sparse-checkout file and run git read-tree again as above. # http://schacon.github.io/git/git-read-tree.html#_sparse_checkout