Re: [PATCH v3 0/2] refs: allow setting the reference directory
- From
Patrick Steinhardt <ps@pks.im>
- Date
- Jan 5, 2026, 15:13 UTC
- Message-ID
- <aVvVAH1eRxGa60Fp@pks.im>
- In-Reply-To
- <20251201-kn-alternate-ref-dir-v3-0-c11b946bc2fa@gmail.com>
On Mon, Dec 01, 2025 at 12:24:57PM +0100, Karthik Nayak wrote:
Show 5 quoted lines
> Changes in v3: > - Cleanup some stale code which wasn't removed. > - Localize strings which will be output to the user. > - Remove additional defensive checks which are not needed. > - Link to v2: https://patch.msgid.link/20251126-kn-alternate-ref-dir-v2-0-8b9f6f18f635@gmail.com
FYI: I did an internal review of this at [1] and mentioned a couple of things that I think still need to be iterated on. Most importantly, I think that we also need to handle worktrees:
I think we need to do something about worktree ref stores in the
context of this series, as we're now thinking a bit broader than
before. It would be somewhat weird if you can change the main
reference store, but it doesn't have any influence on the worktree
ref stores. If I say e.g. that the ref store is located in
`/tmp/dir`, then I'd expect that the main ref store would be in
`/tmp/dir/refs` and that worktree refs are in
`/tmp/dir/worktrees/$name/refs`. The reason I think this needs to be handled as part of this MR is
that we are extending semantics of the extension now. This is only
possible because the extensions are quite strict now, and thus we
can strictly extend them. But once we have extended them we cannot
just alter their semantics to also cover worktree refs.So you can expect another iteration of this patch series once folks settle into their usual post-holiday rhythms again :)
Patrick
[1]: https://gitlab.com/gitlab-org/git/-/merge_requests/451