git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Annoying absolute path for "core.worktree" to submodule
@ 2012-03-20  9:52 Christian Hammerl
  2012-03-20 13:31 ` Antony Male
  0 siblings, 1 reply; 5+ messages in thread
From: Christian Hammerl @ 2012-03-20  9:52 UTC (permalink / raw)
  To: git

Hey folks,

I really love the work you are doing on GIT but the last update
regarding submodules is a bit annoying. Although the path inside the
".git" file is stored relative to the submodule's path, the path in
".git/modules/path-to-submodule/config" is stored as an absolute path
for "core.worktree".

I develop (for some projects) within a chroot where I have a different
username and therefore the path differs if I am currently inside the
chroot or not. If the submodule is initialized inside the chroot, I
always get this message when I cd into the project's directory outside
of the chroot:

fatal: Could not switch to
'/home/chroot-username/parent-path-of-submodule': File or directory not
found
fatal: 'git status --porcelain' failed in submodule
relative-path-to-submodule

This is caused by using `__git_ps1` for my bash-prompt. I don't know
exactly where the problem is and what actions (called by __git_ps1) are
responsible for this.

Any suggestions how to deal with this?

And no, removing __git_ps1 from my bash-prompt is not the answer, I
like this feature very much. ;-)

Thanks in advance
Christian

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2012-03-21 19:42 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-03-20  9:52 Annoying absolute path for "core.worktree" to submodule Christian Hammerl
2012-03-20 13:31 ` Antony Male
2012-03-20 21:39   ` Holding, Lawrence
2012-03-21 19:41     ` Jens Lehmann
2012-03-21  9:42   ` Christian Hammerl

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).