From: Jeff King Date: Tue, 29 Sep 2026 01:44:15 GMT Subject: Re: hostname: includeIf condition — anyone already working on this? Message-ID: <20260929014415.GB1089022@coredump.intra.peff.net> In-Reply-To: On Mon, Sep 28, 2026 at 08:43:49PM -0300, Isabella Caselli wrote: > I found a related proposal from 2022 for an includeIf condition based > on the operating system [2], which stalled over disagreements about > naming and case sensitivity. My understanding is that "hostname:" is a > narrower, separate condition (machine identity, not platform), so I > don't think it needs to revisit that discussion, but I wanted to check > before starting: > > - Is it still relevant for the project? > - If yes, is anyone already working on this issue? I think it's a reasonable feature to have. I don't recall seeing anybody else work on it recently (and a quick search of the list archive confirms). But see below. > - Any objection to the approach itself? The same machine can report > its hostname differently depending on how it's set up — sometimes just > the short name, sometimes with the full network address attached to it > — so it isn't obvious whether the condition should compare that value > exactly as the system reports it, or normalize it somehow before > comparing. Yes, that is the tricky part. :) There were some patches in 2024: https://lore.kernel.org/git/20240307205006.467443-1-ignacio@iencinas.com/ where the issue came up. Based on my recollection and a quick skim of the thread, I think the consensus was that it's OK to document that it is system-dependent whether we'll match against a short of fully qualified hostname. But exposing our view of the hostname via git-var (e.g., "git var GIT_HOSTNAME") might be a helpful debugging aid. It looks like after review on v3 of the series we never saw more. I'd guess the author (cc'd) just never got around to pushing it forward. -Peff