Article View: linux.kernel.git
Article #4176Re: [PATCH v9 3/4] branch: add --delete-integrated to delete rebase and squash merged branches
From: Ben Knoble
Date: Mon, 30 Nov 2026 23:41
Date: Mon, 30 Nov 2026 23:41
62 lines
13918 bytes
13918 bytes
> Le 30 nov. 2026 à 15:22, Harald Nordgren <haraldnordgren@gmail.com> a écrit :
>
>
>>
>>> diff --git a/Documentation/config/branch.adoc b/Documentation/config/branch.adoc
>>> index c2acd89c99..be9b296bda 100644
>>> --- a/Documentation/config/branch.adoc
>>> +++ b/Documentation/config/branch.adoc
>>> @@ -106,7 +106,7 @@ for details).
>>>
>>> `branch.<name>.deleteMerged`::
>>> If set to `false`, branch _<name>_ is exempt from
>>> - `git branch --delete-merged`. Useful for a topic branch you
>>> - intend to develop further after an initial round has been
>>> - merged upstream. Defaults to true. Explicit deletion via
>>> - `git branch -d` is unaffected.
>>> + `git branch --delete-merged` and `--delete-integrated`. Useful
>>> + for a topic branch you intend to develop further after an
>>> + initial round has been merged upstream. Defaults to true.
>>> + Explicit deletion via `git branch -d` is unaffected.
>>
>> Does the deleteMerged configuration variable affect the behavior of
>> the "--delete-integrated" option? Knowing how the feature evolved,
>> it is understandable to me, but I suspect it won't be natural for
>> mere mortals.
>>
>> Perhaps a single .deleteDone variable that governs both would be
>> more future-proof, as it anticipates that we may find other ways a
>> branch becomes "done", other than by getting merged or otherwise
>> integrated, and when that happens this variable will also deal with
>> such a new destructive operation.
>
> I thought about this some more, because I'm sketching out a
> '--delete-merged --remove-worktrees' follow-up, and realized that this
> will need to be added to two places as well, '--delete-merged' and
> '--delete-integrated'.
>
> So it seems maybe it's better to not have '--delete-integrated' as a
> separate thing? Should we unify it now when we still have the chance?
With context well paged out of my working memory, I cannot recall
the distinction between the 2 already. I *guess* one is merged and
the other is non-merge integrations (squash, rebase). But I still find that
more complex than
--delete-integrated[=merged,squashed,rebased]
where we accept more than one comma-separated modifier,
and « all » is an alias for all 3. And possibly the default if none are
specified ?
We could (later) support ^merged or -merged as negatives so that
« all,-merged » means the same as « squashed,rebased ».
And we could *maybe* shoehorn remove-worktrees there, too,
or make it a separate modifier flag.
Anyway, yes, I’m in favor of simplifying and unifying related concepts.
Technical Details
Message-ID:
<1D9D2E5D-904D-4799-B751-AC90913738D4@gmail.com>Path:
mbox-mo1.pugleaf.net!srv.newsdeef.eu!newsfeed.bofh.team!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!git+bounces-76740-linux-kernel-git=dewy.ruReferences:
<CAHwyqnUc19VhV-NWu0GdK5Q2YT01u7ufn2CpSaq_mcpyzupMhg@mail.gmail.com>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!srv.newsdeef.eu!newsfeed.bofh.team!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!git+bounces-76740-linux-kernel-git=dewy.ru
From: ben.knoble@gmail.com (Ben Knoble)
Newsgroups: linux.kernel.git
Subject: Re: [PATCH v9 3/4] branch: add --delete-integrated to delete rebase and squash merged branches
Date: Mon, 30 Nov 2026 18:41:40 -0500
Organization: Usenet Network
Message-ID: <1D9D2E5D-904D-4799-B751-AC90913738D4@gmail.com>
References: <CAHwyqnUc19VhV-NWu0GdK5Q2YT01u7ufn2CpSaq_mcpyzupMhg@mail.gmail.com>
MIME-Version: 1.0 (1.0)
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
Injection-Info: usenet.network;
logging-data="1567905"; mail-complaints-to="abuse@usenet.network"
Cancel-Lock: sha1:ZsVwQLyToLHLjkCEgKt6kRpZwt8= sha256:asFXL6DyjlODG864AWDGwxyj1+bufRppY3twnUHUnj8=
sha1:TvdXDKmX193fMUpkiASZZoqN0WA= sha256:Ve1X7Hmd/AGCVTtlPziwbiJl8mgvqplz0DsbrjetL6w=
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 E0B01126015; Tue, 1 Dec 2026 02:42:17 +0300 (MSK)
X-Virus-Scanned: Debian amavisd-new at usenet.network
X-Spam-Flag: NO
X-Spam-Score: -1.949
X-Spam-Status: No, score=-1.949 tagged_above=-9999 required=6.31
tests=[DCC_CHECK=1.1, 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 1fS6aiSlZUJw;
Tue, 1 Dec 2026 02:42:10 +0300 (MSK)
X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.234.253.10; helo=sea.lore.kernel.org; envelope-from=git+bounces-76740-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 752EC12600C; Tue, 1 Dec 2026 02:41:59 +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 9AD42271E3; Mon, 30 Nov 2026 23:41:54 +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=1796082114;
b=n8bk9XdNNsDCzJ37hXY2VoHQbiukowX63iyDQz7Po59JInIiguDt9+7/UuBMwSN3R+40
1xtqCcYKQp2R2RCcfDHKs0fOdJJy4DHqEzAUUw12ZNJX+HX2n7nFYbHjn7M5fzB4tXoRL
F4KWWIpVxZDDOOQ622uP68aT2AcgMdGnL0/6AGSNnzKnVERwsanlz9SzmGv2NNfQRQCll
42Z49emgCa53iLwCTx3geQ7lzZEtFeafzebWI6dvP0HREjvNTSb+3arITHGB/9vXr5tAT
EkmLq0Ta+Q/zoVMfvFWmLE1DHOChN3R/4IpYsoOhv818QNhZjol2L4bFphVkVBV9tBw==
X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015;
a=rsa-sha256; c=relaxed/relaxed; t=1796082114;
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:Content-Type:Content-Transfer-Encoding:
From:X-Mailing-List:List-Id:List-Post:List-Help:List-Subscribe:
List-Unsubscribe:List-Owner:Precedence:Mime-Version:Subject:Date:
Message-Id:References:Cc:In-Reply-To:To:X-Mailer;
bh=Cc34054S7qoYMEEnBN0KEpWSbJajXvujbnvb3nr6cZo=;
b=vwCEghpJzE1RH+X2z+acezJtrQHeSS+BEjT56BrHoNEZ1+NhVNFJRZSjai1TZR5Fz/bl
OevWgDK2tfD/29SJlQ3AUq9GjdijX7xEo9KxBPa3vl/drg4OAjJllWdc7nX/N3yDXiqB5
z1sJeslGabjjVHly8D9olUl+0VfTwKpZL4nm9nSwVQ6OMkcYbx6xqrKHvBSH5rEAxJWbq
S7W+rio0+JhvVRd1AUBgcaiQH6g8hNSJXQkWHflw3b97YnVexaAOAcqzaJQWgS0thSI9T
9sFdcWX8xtYztqFGJyhKAJoZepFHoaat9X085GoqiRr0aAyEs1I8mb5bN1P9GBrozbw==
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="YzGV/q/K";
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 4A7E3606A32C;
Mon, 30 Nov 2026 23:41:54 +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=YzGV/q/K
X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=209.85.128.181
X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none;
t=1796082113;
b=MrC67Eo7oUGith3bC60xyB6bM4YOJK/D+49vOFL4LObt7v80/uyaE5K4ekI9VYmdAxq/
qMLkz0YsdQY75iNT6oo9BNDMVbU+K2dZ+jPB6ekVmENSgyzI4nrML6/TqNR18bW3+9DtP
6Rg+cqryC01nTVzeWxj9kiWJ/MULBPXHxLI4Hs9TsF6ghOGFO6Chmtk6mK2slJtWxI0vJ
f7nzRHTydx1dj9Mhk7YY3CL8PB7c6mPKQOjihsC7ngwftMFDtxLBLTZPtJbg4MhXwWuj2
9W2/TFFRo1XGmDidqZtpDEmYHusVbF81+/FMlws8TH3pFkq9diTrG4qvzs9bxXRI5sQ==
X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015;
a=rsa-sha256; c=relaxed/relaxed; t=1796082113;
h=DMARC-Filter:Received:DKIM-Signature:X-Google-DKIM-Signature:
X-Forwarded-Encrypted:X-Gm-Message-State:X-Gm-Gg:X-Received:Received:
Content-Type:Content-Transfer-Encoding:From:Mime-Version:Subject:Date:
Message-Id:References:Cc:In-Reply-To:To:X-Mailer;
bh=Cc34054S7qoYMEEnBN0KEpWSbJajXvujbnvb3nr6cZo=;
b=vWjYe4gk6VKxlIzJLaxrsFG9mCEiUb44mtu4qCH45jTp2GlwtrFPcq8JJMLcEAMNa5iC
hAKP4gu1IcSk3yW28xL+QCvLAHKnB6tBpwoFGTEP42g1PmFzo8gdxM/ilE7FLMum6u6+7
qDZTP1kQVa16W03jYWmXwGQnrgRDoj+33nQoS7uhDHB+xQm1KZaNSdLzWzVeWAUwwC2IH
YtBS0W5/APEVmFXdmHoYzSlZxx3NmCNTtRO2X8QubbUT2z8hLPX56xFY9F/ys3IUPQ2Lf
1X0F7sMQu07jKtinIbarP3hdBI669kwDnZUuHwe+69jV3VxA42908HjcbxtEEldKVzQ==
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="YzGV/q/K";
arc=none smtp.remote-ip=209.85.128.181
X-Received: from mail-yw1-f181.google.com (mail-yw1-f181.google.com [209.85.128.181])
(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 002AC606A31A
for <git@vger.kernel.org>; Mon, 30 Nov 2026 23:41:52 +0000 (UTC)
X-DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 002AC606A31A
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-yw1-f181.google.com with SMTP id 00721157ae682-8b2d14968c9so106332267b3.0
for <git@vger.kernel.org>; Mon, 30 Nov 2026 15:41:52 -0800 (PST)
X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=gmail.com; s=20260707; t=1796082112; x=1796686912; darn=vger.kernel.org;
h=to:in-reply-to:cc:references:message-id:date:subject:mime-version
:from:content-transfer-encoding:content-type:from:to:cc:subject:date
:message-id:reply-to:content-type;
bh=Cc34054S7qoYMEEnBN0KEpWSbJajXvujbnvb3nr6cZo=;
b=YzGV/q/KsJ+mol2yOO55vJQUQOhm0HhJ+dEnaZno4AQMZmrKjrujEQKrMyVG5Cpl/i
vDjFtoxcOb/p5T1f9tPpDIL3Op9mcBpLyyhylodpYEQZyakPInCp7lCvp1/NvZEl9JGS
LDXvCEEAGkRliCIlpckuCewpTzfww7x2cdzVKzZQarsgMFVO//MBYxWWRQXDvGXrcMjc
pIHtqbGLh8Xl2rtEV2kL6dONsOPHpTTMIYlV8iLnEvV8YEBRZn+djfydrHe2vSagAfuK
m4oXGt+gDiIXmMMKjH8c7IMSqo7MspWHXGtiLE8S8x2sZ5C2TsTsBMPgKIpMT6BxLnl5
K0ow==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=1e100.net; s=20260707; t=1796082112; x=1796686912;
h=to:in-reply-to:cc:references:message-id:date:subject:mime-version
:from:content-transfer-encoding:content-type:x-gm-gg
:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to
:content-type;
bh=Cc34054S7qoYMEEnBN0KEpWSbJajXvujbnvb3nr6cZo=;
b=sMovmiZDETKCPOrocnZ8FUFiXSc4rnUEC8YkDgKCNHaPaa5/yrCdzj/y/WEHQr0M3M
gCSwBqeQ2r02Diq0+Ei/hYqKkF4H7VkTkBYiVVn3ANlTMvJuziZGH7OYC+1ZK0DnU3rU
mibpOPQgLmVC8MDd6TplqXpddP0BiOlEXK+zTIkj4r2QMih4uScd+2e/qmIC84rVVo2e
ziZAvIqTI2YZYCks5VkhphcwUO60wBNwMH0KA7XBgPmK3J41odjBV3c09adl20o5Q2Om
xNdMniFCxs5MXEFd78Xwk4aiN3vRlIAn2AU4LibkYT6gd2ilhbJADtF8mEF5KPsfvdp6
QpzA==
X-Forwarded-Encrypted: i=1; AL+hErHNWtY9vSWiwIlYPKppCsvF48y54Zl+hzEfpe6KPZjFthKvGqv1PbxxEFWxMj5OOR4S7q0=@vger.kernel.org
X-Gm-Message-State: APuU4Z9BSEgTIY+kcF7/3/Ug9rESshzVm0cbOXT+4OfHWCFgTseI2440
1yndbzJEeC8vCvgIngHa7KILEn2k9HXtL8iV55UpAL/PNhJ5WZffuqj0
X-Gm-Gg: AZFdTZfoU6xRCxJu7hHVQ4m3KpBtnugU96MDiau+sWd06HmeHJys2xtL0WDHBvxYg5a
Q0tunwsH576QpOsO9isB0PhMGZgsnB5i3sbOPiuJZbmvM1n+5v/UAXiaFG3MJL/Zo5qWctC/z1D
+yF/0SWsuWVXROkfUM2rBcosIGC02DBF7PWWNlOpYTrIfJTyrGpx0tocPIlv452DLgoAfh/EcVV
5tIJ5X3Enqf5BEqUHzmEh84NI17dpVLUKRXQCYLgeTKwIFcHzrlwT7Om1S2+aPkqjmIV+JqZSkX
50zkH/ULHkCM71UkkK6sXuAWvo6phELOkZVOWxTq7SQjiLfLVDAUPiKCxHWwd8byouAdvlJl2Hi
t7D10GZzt7GU28NgOYCxZOJ5HH3qk07Jg1reIBW/nbHdgLL++xe6Ld7EVx2vQhoL4TfRLPk01GG
6HqIT3x0lS307/SxaotP+BGzfKJ+YJYW7o2dvn5SPOLuLwvswgvO1V2XNk6Gutkg9iao531Twc5
FAThrJJLpBoasYp94pAhw9UApYVlS8hpTYFS1b8ytZmj8zcQiBB9MxZtjdzAJaEdetIZucEW2Uc
TQ2EpoxBXMZCLPyWHTeXnk0YHaGoRkb+3iGLn0VGcRnrz51hVRIS8A2AwFoXBhn77LThy6TnMhs
6vZQ3e1xtjKldQoUK6DAutoEeUErH6zGJ51ZPnWS/tHWCMgJlNAwqfZeM2cy/m8rwxcFcGMYzG7
E3hw==
X-Received: by 2002:a05:690c:6c86:b0:8b3:c81:aba3 with SMTP id 00721157ae682-8b5204ab3e5mr118332897b3.40.1796082111856;
Mon, 30 Nov 2026 15:41:51 -0800 (PST)
X-Received: from smtpclient.apple ([2605:a601:9d46:600:b80c:bb2d:2327:e685])
by smtp.gmail.com with ESMTPSA id 00721157ae682-8b5202b085bsm137936687b3.16.2026.11.30.15.41.50
(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);
Mon, 30 Nov 2026 15:41:51 -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-Cc: Junio C Hamano <gitster@pobox.com>,
Harald Nordgren via GitGitGadget <gitgitgadget@gmail.com>,
git@vger.kernel.org,
Kristoffer Haugsbakk <kristofferhaugsbakk@fastmail.com>,
Phillip Wood <phillip.wood123@gmail.com>,
Jasper Mayone <me@jaspermayone.com>, Tuomas Ahola <taahol@utu.fi>
X-In-Reply-To: <CAHwyqnUc19VhV-NWu0GdK5Q2YT01u7ufn2CpSaq_mcpyzupMhg@mail.gmail.com>
X-Mailer: iPhone Mail (23D8133)