Git development
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: "René Scharfe" <l.s.r@web.de>
Cc: Patrick Steinhardt <ps@pks.im>,  git@vger.kernel.org
Subject: Re: [PATCH 5/5] use repo_hold_lock_file_for_update{,_mode,_timeout}() with custom repos
Date: Sun, 19 Jul 2026 12:11:46 -0700	[thread overview]
Message-ID: <xmqqmrvmn6a5.fsf@gitster.g> (raw)
In-Reply-To: <3c0a8031-7082-422a-b474-938418682b60@web.de> ("René Scharfe"'s message of "Sat, 18 Jul 2026 08:35:37 +0200")

René Scharfe <l.s.r@web.de> writes:

> On 7/15/26 11:52 AM, Patrick Steinhardt wrote:
>> On Tue, Jul 14, 2026 at 07:59:56PM +0200, René Scharfe wrote:
>>> Apply the config setting core.sharedRepository from the repository at
>>> hand instead of from the_repository.
>> 
>> We only do this for a subset of callsites, apparently. How did you
>> select which subsystems to convert and which not to? To make this
>> explicit: I don't mind a partial migration, but I think the commit
>> message should briefly explain the reasoning behind it.
>
> All those that have a repository reference other than the_repository.
>
>> Also, as you don't get rid of the old functions that still implicitly
>> depend on `the_repository`, I think we should have an additional commit
>> on top that guards all functions that have this implicit dependency with
>> `USE_THE_REPOSITORY_VARIABLE`. This ensures that we cannot accidentally
>> call such functions from other subsystems that already got rid of the
>> global dependency.
>
> Probably, but the lockfile conversions deserve their own patch series.
> Patch 5 is only included here because it was easy to write.  We can drop
> it and leave the low-hanging fruit on the tree if that's preferable.

I am personally indifferent as to what we do immediately in this
series, as long as we all agree on the longer-term direction.  It
seems we are in agreement on providing additional safety in the
medium term?

Thanks.

  reply	other threads:[~2026-07-19 19:11 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-14 17:59 [PATCH 0/5] tempfile: stop using the_repository René Scharfe
2026-07-14 17:59 ` [PATCH 1/5] tempfile: add repo_create_tempfile{,_mode}() René Scharfe
2026-07-15  9:52   ` Patrick Steinhardt
2026-07-15 11:25     ` René Scharfe
2026-07-14 17:59 ` [PATCH 2/5] refs/packed: use repo_create_tempfile() René Scharfe
2026-07-14 17:59 ` [PATCH 3/5] lockfile: add repo_hold_lock_file_for_update{,_timeout}{,_mode}() René Scharfe
2026-07-14 17:59 ` [PATCH 4/5] tempfile: stop using the_repository René Scharfe
2026-07-15  9:52   ` Patrick Steinhardt
2026-07-14 17:59 ` [PATCH 5/5] use repo_hold_lock_file_for_update{,_mode,_timeout}() with custom repos René Scharfe
2026-07-15  9:52   ` Patrick Steinhardt
2026-07-18  6:35     ` René Scharfe
2026-07-19 19:11       ` Junio C Hamano [this message]
2026-07-14 20:45 ` [PATCH 0/5] tempfile: stop using the_repository Junio C Hamano
2026-07-15  9:51 ` Patrick Steinhardt

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=xmqqmrvmn6a5.fsf@gitster.g \
    --to=gitster@pobox.com \
    --cc=git@vger.kernel.org \
    --cc=l.s.r@web.de \
    --cc=ps@pks.im \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox