I expect I unintentionally created a nested get repo (locally), either by creating a git repo on a higher level or on a lower level.
Is there a quick way to check out if this is the case?
Thanks!
I expect I unintentionally created a nested get repo (locally), either by creating a git repo on a higher level or on a lower level.
Is there a quick way to check out if this is the case?
Thanks!
After asking this question I realized I can just search directories for existing git repo's, and I found a way to do this, from another StackOverflow thread:
running this command in a directory (on Linux) seems to list all git repo's somewhere down the directory tree:
find . -type d -exec sh -c 'cd "{}"; git rev-parse --git-dir 2> /dev/null 1>&2' \; -prune -print
Credits go to CharlieB, answer found here
Note
Initially I wondered if the command had worked, since the only output I got was a dot (.
). But of course this meant that the directory I was running this in was a git repo itself.
Running it a level higher gave me the full directory name instead:
$ find . -type d -exec sh -c 'cd "{}"; git rev-parse --git-dir 2> /dev/null 1>&2' \; -prune -print
./01_introduction