Re: [PATCH 04/10] Make setup_work_tree() return new prefix
- From
Nguyen Thai Ngoc Duy <pclouds@gmail.com>
- Date
- Mar 11, 2008, 15:18 UTC
- Message-ID
- <fcaeb9bf0803110818t6c009b29k5afb4f8b3833d475@mail.gmail.com>
- In-Reply-To
- <alpine.LSU.1.00.0803111426521.3873@racer.site>
On Tue, Mar 11, 2008 at 8:27 PM, Johannes Schindelin <Johannes.Schindelin@gmx.de> wrote:
Show 11 quoted lines
> Hi, > > > On Sun, 2 Mar 2008, Nguyễn Thái Ngọc Duy wrote: > > > worktree setup inside setup_git_directory*() is not perfect. It does not > > take core.worktree into account. So when you do setup_work_tree(), the > > real work tree may be not the one setup_git_directory*() gives you. You > > need a new prefix in that case. > > Probably the real fix would be to setup_git_directory(), no?
setup_work_tree() does the job fine. Why duplicate the code one more? In the old days, setup_git_directory() was just a simple wrapper around setup_git_dir_gently(). I wanted to move it back to those days. And setup_git_directory() is fixed in "Completely move out worktree setup from setup_git_directory_gently()" so setup_git_directory() does contain the real fix in the end.
> Ciao, > Dscho
-- Duy