Created
February 8, 2014 01:22
-
-
Save mbijon/8875213 to your computer and use it in GitHub Desktop.
git checkout/clone over the top of an existing set of files
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
git clone --no-checkout repo-address subdir/tmp | |
mv subdir/tmp/.git subdir/.git/ # final "/" important | |
rm -Rf subdir/tmp | |
cd subdir | |
git reset --hard HEAD |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment