Re: [RFC/PATCH] clone: introduce clone.submoduleGitDir to relocate $GITDIR
- From
Ramkumar Ramachandra <artagnon@gmail.com>
- Date
- Apr 17, 2013, 10:53 UTC
- Message-ID
- <CALkWK0kw69rMveDXpGEvV=fGxiQ7JoT_JE9ZU5cor0xD=BUbFQ@mail.gmail.com>
- In-Reply-To
- <CACsJy8D-5x5HXgpr2hHUHee6jcfj3++b961sJB_aKTZC1ZS+tw@mail.gmail.com>
Duy Nguyen wrote:
Show 5 quoted lines
> What if I clone a repo then realize it was a mistake and remove it? > With current clone, a "rm -rf" would do. With this, I'll need to > figure out which subdir in the top .git contains the repo I want to > remove. I'm not sure how "git submodule" handles this case though > (i.e. total submodule ignorant speaking..)
Currently, submodules relocate the GITDIR of submodules to .git/modules. So, my proposed patch doesn't make the situation any worse. In fact, it improves the situation because you're guaranteed that all your GITDIRs will be in ~/bare (or whatever your core.submoduleGitDir is), as opposed to a complex path in .git/modules of your containing superproject.