Thread (9 messages) flat view 9 messages, 4 authors, 2016-06-15

Re: [PATCH] Preserve cwd in setup_git_directory()

From: Nguyen Thai Ngoc Duy <hidden>
Date: 2016-06-15 22:45:00

On 7/24/08, Johannes Schindelin [off-list ref] wrote:
Hi,


 On Thu, 24 Jul 2008, Nguyen Thai Ngoc Duy wrote:

 > When GIT_DIR is not set, cwd is used to determine where .git is. If
 > core.worktree is set, setup_git_directory() needs to jump back to the
 > original cwd in order to calculate worktree, this leads to incorrect
 > .git location later in setup_work_tree().


I do not understand.  core.worktree is either absolute, in which case
 there is no problem.  Or it is relative to where the config lives, no?
The problem is GIT_DIR is not absolute in this case. So cwd must stay
where git dir is until it is absolute-ized by setup_work_tree().

-- 
Duy
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help