Last active
December 1, 2017 16:03
-
-
Save chalstrick/c743b10b1ccd7a6954f12260ea0c59b9 to your computer and use it in GitHub Desktop.
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 characters
git init subRepo | |
cd subRepo/ | |
touch a | |
git add a | |
git commit -m addA | |
cd .. | |
git init rootRepo | |
cd rootRepo/ | |
touch b | |
git add b | |
git commit -m addB | |
git branch side | |
git submodule add ../subRepo/ sub | |
git commit -m addSub | |
git tag withSub | |
git reset --soft side | |
rm -fr sub | |
git checkout withSub | |
ls | |
## See how native git doesn't touch the filesystem because index==MERGE. If index==MERGE git thinks there is nothing to do. | |
## But JGit thinks the index has to be updated and therefore also populates the working tree. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment