From: Johannes Sixt Date: Sat, 23 May 2026 08:18:59 GMT Subject: Re: [PATCH v2 01/11] git-gui: guard set/unset of GIT_DIR and GIT_WORK_TREE Message-ID: In-Reply-To: Am 22.05.26 um 13:54 schrieb Mark Levedahl: > The manual page is incomplete: if the repository has set core.worktree=/somehere, that is > the root of the worktree and the current directory is always ignored. git rev-parse will > report /somewhere as the answer to --show-toplevel regardless of current directory, even > if inside the gitdir, and even if GIT_DIR is used. > > The user can override with GIT_WORK_TREE, and if so we must keep GIT_WORK_TREE in the > environment if it was set. [...] Oh, well, these intricacies! Let's scrap my patch and keep yours. The other patch that removes cd $_gitworktree from do_gitk should still be good, I think. -- Hannes