Article View: linux.kernel.git
Article #3059Re: [PATCH v13 1/6] fetch: add remote.<name>.fetchRefmap
From: Phillip Wood
Date: Fri, 13 Nov 2026 09:48
Date: Fri, 13 Nov 2026 09:48
57 lines
13654 bytes
13654 bytes
On 12/11/2026 19:49, Junio C Hamano wrote:
> Phillip Wood <phillip.wood123@gmail.com> writes:
>
>>> When remote.<name>.fetch is also configured, it still decides what to
>>> fetch, and the refmap maps what it fetches. This lets a remote name
>>> only a few branches and store them all through one refmap:
>>>
>>> [remote "cabal"]
>>> fetch = master
>>> fetch = next
>>> fetch = seen
>>> fetchRefmap = +refs/heads/*:refs/remotes/cabal/*
>>
>
> If .fetch is a refspec with a right hand side that stores the
> result somewhere, and that somewhere is different from what the
> .fetchRefmap suggests should happen, what happens?
>
> I think we tried earlier and saw that we store them twice [*], even
> without this series (i.e., specifying both refspec and refmap from
> the commmand line). As it is a long-standing behavior since the
> --refmap feature was introduced, and I do not see huge problem with
> that behavior, I am not sure if it is worth tweaking.
If we want to be able to use "remote.<name>.fetchRefmap" to specify how
to map the names of fetched refs without specifying the default set of
refs to fetch then I don't think we want
git -c 'remote.cabal.fetchRefmap=refs/heads/*:refs/remotes/cabal/*'
master feature:wip/feature
to update "refs/remotes/cabal/feature" when we gave a destination for
"feature" on the command line. The existing behavior is long-standing
but I wonder how often people specify a destination in the commandline
refspec when they pass --refmap, so would anyone really notice if we
changed it?
> But if it is
> wroth tweaking, we probably should do so as a preliminary clean-up
> before all of this, since .fetchRefmap is merely a way to allow you
> to avoid having to specify --refmap from the command line all the
> time, and this series does not change its semantics until step
> [3/6].
I agree with having a separate patch to handle the cleanup, though as I
said elsewhere I think we should drop patch 3 and use the combination of
".fetchRefmap" and ".fetch" to set the default behavior when there are
no refspecs on the commandline.
Thanks
Phillip
> [Reference]
>
> * https://lore.kernel.org/git/xmqqld7hafhy.fsf@gitster.g/
Technical Details
Message-ID:
<5125fcec-7764-416c-ab78-58cc22cd415d@gmail.com>Path:
mbox-mo1.pugleaf.net!news-lax.pugleaf.net!srl.newsdeef.eu!newsfeed.bofh.team!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!git+bounces-75363-linux-kernel-git=dewy.ruReferences:
<pull.2412.git.git.1789829246437.gitgitgadget@gmail.com> <pull.2412.v13.git.git.1793357550.gitgitgadget@gmail.com> <07081828d1d65373bee4b2ef5e1916e65a217db6.1793357550.git.gitgitgadget@gmail.com> <01a799bc-5493-4984-8b83-7f2aef698f85@gmail.com> <xmqqv761hltu.fsf@gitster.g>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-lax.pugleaf.net!srl.newsdeef.eu!newsfeed.bofh.team!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!git+bounces-75363-linux-kernel-git=dewy.ru
From: phillip.wood123@gmail.com (Phillip Wood)
Newsgroups: linux.kernel.git
Subject: Re: [PATCH v13 1/6] fetch: add remote.<name>.fetchRefmap
Date: Fri, 13 Nov 2026 09:48:34 +0000
Organization: Usenet Network
Message-ID: <5125fcec-7764-416c-ab78-58cc22cd415d@gmail.com>
References: <pull.2412.git.git.1789829246437.gitgitgadget@gmail.com>
<pull.2412.v13.git.git.1793357550.gitgitgadget@gmail.com>
<07081828d1d65373bee4b2ef5e1916e65a217db6.1793357550.git.gitgitgadget@gmail.com>
<01a799bc-5493-4984-8b83-7f2aef698f85@gmail.com> <xmqqv761hltu.fsf@gitster.g>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Info: usenet.network;
logging-data="1333996"; mail-complaints-to="abuse@usenet.network"
Cancel-Lock: sha1:XQxXCUH0AjEW++lZcEoY1o0sKgQ= sha256:M1NlTSUq4Lu44fDKaPK9CEGTwQtuSvaQVrgGVWFg3OY=
sha1:OutxX/k+4yPBQFAGOUo4RlRDKrA= sha256:XWfanD9ufuoCf3nVHyEnYZlAUjQAzKwdq105EPJtLQE=
Content-Language: en-US
List-ID: <git.vger.kernel.org>
X-Mailpost-Empty-Hdrs: X-Spam-Level
X-Received: from localhost (localhost [127.0.0.1])
by mail.dewy.ru (Postfix) with ESMTP id F293C114516; Fri, 13 Nov 2026 15:12:48 +0300 (MSK)
X-Virus-Scanned: Debian amavisd-new at usenet.network
X-Spam-Flag: NO
X-Spam-Score: -3.049
X-Spam-Status: No, score=-3.049 tagged_above=-9999 required=6.31
tests=[DCC_REPUT_70_89=0.1, DKIM_SIGNED=0.1, DKIM_VALID=-0.1,
DKIM_VALID_AU=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.001,
FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.249,
MAILING_LIST_MULTI=-1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001,
SPF_PASS=-0.001] autolearn=ham autolearn_force=no
X-Authentication-Results: mail.dewy.ru (amavisd-new); dkim=pass (2048-bit key)
header.d=gmail.com
X-Received: from mail.dewy.ru ([127.0.0.1])
by localhost (mail.dewy.ru [127.0.0.1]) (amavisd-new, port 10024)
with ESMTP id Wfrkg-mjOXgn;
Fri, 13 Nov 2026 15:12:45 +0300 (MSK)
X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.234.253.10; helo=sea.lore.kernel.org; envelope-from=git+bounces-75363-linux-kernel-git=dewy.ru@vger.kernel.org; receiver=<UNKNOWN>
X-Authentication-Results: OpenDMARC; dmarc=fail (p=none dis=none) header.from=gmail.com
X-Received: from sea.lore.kernel.org (sea.lore.kernel.org [172.234.253.10])
by mail.dewy.ru (Postfix) with ESMTPS id 3ED6B1144EF; Fri, 13 Nov 2026 15:12:37 +0300 (MSK)
X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92])
by sea.lore.kernel.org (Postfix) with ESMTP id A32D42C5BAD; Fri, 13 Nov 2026 09:48:44 +0000 (UTC)
X-Authentication-Results: smtp.subspace.kernel.org; arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1
X-ARC-Seal: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=pass;
t=1794563319;
b=cfL6s2b+rTjil07fAVa7wpnTC/97cK2ilcqlTFuEtyIxMYeBOvHq/HTY/jivZMPKKs3t
nKpf2k7cuuvjLaokqwB6ecRMmXnXxfqMNW5bKEDUqM+7nB+46R4aa/gU0jYIGcQLo350U
9PK44LmMZY/I23XyGSbiT5MKdTHFRbCmwyslu704kP/7jZh2oPGyY9JDN768H17bd+Fp9
JeJYclOzWprPJzvqetZeAqN6Nyer66waQBmOlTopg2730Jy7pMwRXwPJ/2isoqd3pphEb
3O3wpgdewKYSIYvwct7TZucJR0mT3jg84GA+8n2vP3YYH8YDg8QlJJHEqfhVdbDi7Cw==
X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015;
a=rsa-sha256; c=relaxed/relaxed; t=1794563319;
h=X-Original-To:Received:DMARC-Filter:Received:DKIM-Signature:
X-Google-DKIM-Signature:X-Forwarded-Encrypted:X-Gm-Message-State:
X-Gm-Gg:X-Received:Received:Message-ID:Date:X-Mailing-List:List-Id:
List-Post:List-Help:List-Subscribe:List-Unsubscribe:List-Owner:
Precedence:MIME-Version:User-Agent:From:Reply-To:Subject:To:Cc:
References:Content-Language:In-Reply-To:Content-Type:
Content-Transfer-Encoding;
bh=ojs2D4KKFZr7/uPmQEMQt9ixXOWW/qKGA55rZE7bqmY=;
b=xD3IRnjzKfYkpC/BoCO39LXXTSIHbysLw+JO/xwk6ydCaQ43pzfOPLsTb2Hl99NMm4qP
eKer+WdTPm1UEjB+RVq9wNbHaTDtlHB1RLrrXlDA4qVL1a+U/Q/UIodAhbwbGatFXpB2r
2F7QtfLECFoJnAk2CxdTGbm7i9+y2CZPBnRbvOLb58r/oB8ylFdUqOHaUKxqIMnmXSnpF
RirEXTWl7X9LqZS8TcbE0NUqCfKmGdTct9P31eM69TmbcIJZC0csAN4zx6i6nfl1RdBYg
nbiA7/DEkwBB/Ml92xlnFqnNQE2PW6a7BNXZityAM1vM90Sie0LYB5FFJbDfDa5WPoQ==
X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org;
dkim=pass header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20260707 header.b=MkwIOKXE;
dmarc=pass header.from=gmail.com;
spf=pass smtp.mailfrom=gmail.com;
arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1
X-Received: from localhost.localdomain (localhost [127.0.0.1])
by smtp.subspace.kernel.org (Postfix) with ESMTP id E4716606A33F;
Fri, 13 Nov 2026 09:48:38 +0000 (UTC)
X-Authentication-Results: smtp.subspace.kernel.org;
dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20260707 header.b=MkwIOKXE
X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=209.85.128.48
X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none;
t=1794563318;
b=s/hZJVAKOft4LmJZjqXrdT3vZcdL48dT5gbIlFFeam3Esr0VTkiD91qo0Ja+kvWwsbQA
L72Hv9qaY4TC3yNdaOusDlSaRl+FBOWZkxJmKFc06Ql778MWgYf2kEVDozLpyroW8CyDJ
GlsNAqBHXpBN+vZF1cYkzll38e59K/BdW11COiGAlqbtLCGqLToOtQ8r2VUG3I6/rvIla
XJYKZoDQMQz542DH/X3VX0IPAeMmLS29fSIMEYotD79rpciDgUkgj4RWbCztPvWHTZajk
nAiMqN07fuuxgc2uWeVy85p0gMm7dfrEEAptghW0dcUsnstZpISr00JPpjjEeWsgprA==
X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015;
a=rsa-sha256; c=relaxed/relaxed; t=1794563318;
h=DMARC-Filter:Received:DKIM-Signature:X-Google-DKIM-Signature:
X-Forwarded-Encrypted:X-Gm-Message-State:X-Gm-Gg:X-Received:Received:
Message-ID:Date:MIME-Version:User-Agent:From:Reply-To:Subject:To:Cc:
References:Content-Language:In-Reply-To:Content-Type:
Content-Transfer-Encoding;
bh=ojs2D4KKFZr7/uPmQEMQt9ixXOWW/qKGA55rZE7bqmY=;
b=kq4P1YWzhzMFMD2S2HmpBGc7du5FoVgSKkiRJUv4rCXyS8POeR0HZ4ceLQfmGQdl3PrC
qxHBzG/cuarUP3KZSuxR8ca2hsXE4WxqACxkjTKCuU8h1KaxCJUe9kFXii7jSsOPTQgNv
2seaej4nJmD9vMYuOcO8iroK89Zvyvmn9kLYhXtQ016MGZlJ+VPMdm9FErSsMhBM0Nww7
PNFFFu2roEV3WcMOewdSLHXc3YllHEHz5CAxEAXdAsGHm7V5lt45054/mJmRWa6bVYZJ7
DqBjil93ewjdmBzqgmxoOhwFJB+tU7HsZOrcPcbFztrxpCUdwfvXhVET0SrnnFu4ocA==
X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org;
dmarc=pass header.from=gmail.com;
spf=pass smtp.mailfrom=gmail.com;
dkim=pass header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20260707 header.b=MkwIOKXE;
arc=none smtp.remote-ip=209.85.128.48
X-Received: from mail-wm1-f48.google.com (mail-wm1-f48.google.com [209.85.128.48])
(using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)
key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256)
(No client certificate requested)
by smtp.subspace.kernel.org (Postfix) with ESMTPS id B939F606A339
for <git@vger.kernel.org>; Fri, 13 Nov 2026 09:48:37 +0000 (UTC)
X-DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org B939F606A339
X-Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com
X-Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com
X-Received: by mail-wm1-f48.google.com with SMTP id 5b1f17b1804b1-4a35db1f202so4919345e9.3
for <git@vger.kernel.org>; Fri, 13 Nov 2026 01:48:37 -0800 (PST)
X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=gmail.com; s=20260707; t=1794563316; x=1795168116; darn=vger.kernel.org;
h=content-transfer-encoding:content-type:in-reply-to:content-language
:references:cc:to:subject:reply-to:from:user-agent:mime-version:date
:message-id:from:to:cc:subject:date:message-id:reply-to:content-type;
bh=ojs2D4KKFZr7/uPmQEMQt9ixXOWW/qKGA55rZE7bqmY=;
b=MkwIOKXEIjki31rkPWwCWbMvgM2B3C9MzcILN/X81wqKniYH38IhJu8nJqQQf8KXgK
w+E3X6qqgooSKUhAw71bpUf0cLQb7wM5DQW35enaeo1QG7jG0foXLfYrZ7dlcRN4oYNu
yql39WK3SeeUrCYhT9RdiOarxMnM6Ol6zf9TU5lGDM9FzzvnF8w76RP0a0wrvOo/yoEz
RDxrM8/gfytYkT7l4eFwWfy0oi7adfcsSqJf6thQSj/tgK19usWHW3pzjHrEEeahfIZQ
WVr9E+LAF1Uu+VkSJ6iIHdQnUhuISbkYMgbZ7nWILdDICxrMYW4VR/03JKXwEGrvabpL
trjA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=1e100.net; s=20260707; t=1794563316; x=1795168116;
h=content-transfer-encoding:content-type:in-reply-to:content-language
:references:cc:to:subject:reply-to:from:user-agent:mime-version:date
:message-id:x-gm-gg:x-gm-message-state:from:to:cc:subject:date
:message-id:reply-to:content-type;
bh=ojs2D4KKFZr7/uPmQEMQt9ixXOWW/qKGA55rZE7bqmY=;
b=OTMs5iEX4J6J6zoojFb0QZLPek9BRWf/YUiOOoqLvYFsukCCYCnWbvSJrvn+CL3EXZ
PJ2TckNsDWQQRgPJlzgqtNZENszGxahc+KQJVOSqH+wlKN/qu2GISBEArr+9NGthWrp8
mOSZ0gfyvocZOnaPdes6rb9w/o9UczxPg/VHkoWcxEmPzV28iGteP7UipsO1UrDj2hT8
lvcjEfldzenEAkijuNpH4UHp6wOw5BIzzsybaAbd1V3LPZJtudmWGIwePMFnISH2xwQt
tozY1YqIq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745355e9.27.1794563315813;
Fri, 13 Nov 2026 01:48:35 -0800 (PST)
X-Received: from ?IPV6:2a0a:ef40:724:6601:f3ff:aebc:61f8:d91f? ([2a0a:ef40:724:6601:f3ff:aebc:61f8:d91f])
by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-4bb55afb6absm51977275e9.15.2026.11.13.01.48.34
(version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128);
Fri, 13 Nov 2026 01:48:35 -0800 (PST)
X-Mailing-List: git@vger.kernel.org
X-List-Post: <mailto:git@vger.kernel.org>
X-List-Help: <mailto:git+help@vger.kernel.org>
X-List-Subscribe: <mailto:git+subscribe@vger.kernel.org>
X-List-Unsubscribe: <mailto:git+unsubscribe@vger.kernel.org>
X-List-Owner: <mailto:git+owner@vger.kernel.org>
X-Precedence: list
X-User-Agent: Mozilla Thunderbird
X-Reply-To: phillip.wood@dunelm.org.uk
X-Cc: Harald Nordgren via GitGitGadget <gitgitgadget@gmail.com>,
git@vger.kernel.org, "D. Ben Knoble" <ben.knoble@gmail.com>,
Harald Nordgren <haraldnordgren@gmail.com>
X-In-Reply-To: <xmqqv761hltu.fsf@gitster.g>