GNU logs - #50363, boring messages


Message sent to guix-patches@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: [bug#50363] [PATCH v2] Improve default diff hunk header detection.
Resent-From: Sarah Morgensen <iskarian@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: guix-patches@HIDDEN
Resent-Date: Fri, 03 Sep 2021 22:40:01 +0000
Resent-Message-ID: <handler.50363.B.163070876411669 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: report 50363
X-GNU-PR-Package: guix-patches
X-GNU-PR-Keywords: patch
To: 50363 <at> debbugs.gnu.org
X-Debbugs-Original-To: guix-patches@HIDDEN
Received: via spool by submit <at> debbugs.gnu.org id=B.163070876411669
          (code B ref -1); Fri, 03 Sep 2021 22:40:01 +0000
Received: (at submit) by debbugs.gnu.org; 3 Sep 2021 22:39:24 +0000
Received: from localhost ([127.0.0.1]:46029 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1mMHqF-000329-KC
	for submit <at> debbugs.gnu.org; Fri, 03 Sep 2021 18:39:23 -0400
Received: from lists.gnu.org ([209.51.188.17]:59120)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <iskarian@HIDDEN>) id 1mMHq7-00031u-67
 for submit <at> debbugs.gnu.org; Fri, 03 Sep 2021 18:39:21 -0400
Received: from eggs.gnu.org ([2001:470:142:3::10]:41356)
 by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <iskarian@HIDDEN>) id 1mMHq6-00024P-Vm
 for guix-patches@HIDDEN; Fri, 03 Sep 2021 18:39:14 -0400
Received: from out2.migadu.com ([2001:41d0:2:aacc::]:10642)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <iskarian@HIDDEN>) id 1mMHq4-00085a-FU
 for guix-patches@HIDDEN; Fri, 03 Sep 2021 18:39:14 -0400
X-Report-Abuse: Please report any abuse attempt to abuse@HIDDEN and
 include these headers.
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mgsn.dev; s=key1;
 t=1630708748;
 h=from:from:reply-to:subject:subject:date:date:message-id:message-id:
 to:to:cc:mime-version:mime-version:
 content-transfer-encoding:content-transfer-encoding;
 bh=IBSs7glMitEYgu7Vy9BZBhSgGazJt+PyVtxbTTs6hSk=;
 b=Yn9ipum4YxeeeZOiUJ/kqcjh/1+esUbJpJ9e3E0kdJdHMk0x76uzCuRwtTCfhjTig5Pjk0
 dKh1qWVCUYyNXZgMOYNUt/+ElNpDZE99R16ul18PrIX08qaJ6dAlke1O7009K0C+tVjebw
 de/wtr15yUMw4jw1pu0Dl+pMKajzVeU=
From: Sarah Morgensen <iskarian@HIDDEN>
Date: Fri,  3 Sep 2021 15:39:05 -0700
Message-Id: <e6e08312afa17ee812f8b538118bec6da86d3357.1630708121.git.iskarian@HIDDEN>
MIME-Version: 1.0
Content-Transfer-Encoding: 8bit
X-Migadu-Flow: FLOW_OUT
X-Migadu-Auth-User: iskarian@HIDDEN
Received-SPF: pass client-ip=2001:41d0:2:aacc::;
 envelope-from=iskarian@HIDDEN; helo=out2.migadu.com
X-Spam_score_int: -27
X-Spam_score: -2.8
X-Spam_bar: --
X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1,
 DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1,
 RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_NONE=0.001,
 SPF_PASS=-0.001 autolearn=ham autolearn_force=no
X-Spam_action: no action
X-Spam-Score: 0.9 (/)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -2.4 (--)

Tell git to look for top-level definitions for diff hunk headers in
Scheme files.

.gitattributes: New file.
.gitconfig: New file.
---
Hello Guix,

This patch improves the diff hunk headers for diffs on scheme files in this
repository.  These settings are always settable (and overridable) on a
per-user basis, but I think having them as defaults is nice.

This may help with patches applying in general, but the main goal is to make
etc/committer.scm a little less brittle.

The default "scheme" function regex (enabled with .gitattributes) recognizes
both toplevel and non-toplevel defines.  I've modified the regex in .gitconfig
to only recognize the toplevel defines.  I think this makes more sense for our
purposes.

Unfortunately, checked-in git config settings cannot be automatically used
(for security reasons), and must be enabled with a once-per-clone

  git config --local include.path ../.gitconfig

which isn't ideal.  I suppose we could make a 'make' target for setup like
this if we wanted to make it easy.

WDYT?

--
Sarah

 .gitattributes | 2 ++
 .gitconfig     | 2 ++
 2 files changed, 4 insertions(+)
 create mode 100644 .gitattributes
 create mode 100644 .gitconfig

diff --git a/.gitattributes b/.gitattributes
new file mode 100644
index 0000000000..5c1b15e9e0
--- /dev/null
+++ b/.gitattributes
@@ -0,0 +1,2 @@
+*.scm       diff=scheme
+*.scm.in    diff=scheme
diff --git a/.gitconfig b/.gitconfig
new file mode 100644
index 0000000000..344d829824
--- /dev/null
+++ b/.gitconfig
@@ -0,0 +1,2 @@
+[diff "scheme"]
+	xfuncname = "^(\\(define.*)$"

base-commit: 522a3bf99cbc21a9093f63280b9508cd69b94ff0
-- 
2.31.1





Message sent:


Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
MIME-Version: 1.0
X-Mailer: MIME-tools 5.505 (Entity 5.505)
Content-Type: text/plain; charset=utf-8
X-Loop: help-debbugs@HIDDEN
From: help-debbugs@HIDDEN (GNU bug Tracking System)
To: Sarah Morgensen <iskarian@HIDDEN>
Subject: bug#50363: Acknowledgement ([PATCH v2] Improve default diff hunk
 header detection.)
Message-ID: <handler.50363.B.163070876411669.ack <at> debbugs.gnu.org>
References: <e6e08312afa17ee812f8b538118bec6da86d3357.1630708121.git.iskarian@HIDDEN>
X-Gnu-PR-Message: ack 50363
X-Gnu-PR-Package: guix-patches
X-Gnu-PR-Keywords: patch
Reply-To: 50363 <at> debbugs.gnu.org
Date: Fri, 03 Sep 2021 22:40:01 +0000

Thank you for filing a new bug report with debbugs.gnu.org.

This is an automatically generated reply to let you know your message
has been received.

Your message is being forwarded to the package maintainers and other
interested parties for their attention; they will reply in due course.

Your message has been sent to the package maintainer(s):
 guix-patches@HIDDEN

If you wish to submit further information on this problem, please
send it to 50363 <at> debbugs.gnu.org.

Please do not send mail to help-debbugs@HIDDEN unless you wish
to report a problem with the Bug-tracking system.

--=20
50363: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D50363
GNU Bug Tracking System
Contact help-debbugs@HIDDEN with problems


Message received at control <at> debbugs.gnu.org:


Received: (at control) by debbugs.gnu.org; 3 Sep 2021 22:57:47 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri Sep 03 18:57:47 2021
Received: from localhost ([127.0.0.1]:46119 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1mMI83-0003YU-Cv
	for submit <at> debbugs.gnu.org; Fri, 03 Sep 2021 18:57:47 -0400
Received: from out1.migadu.com ([91.121.223.63]:49383)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <iskarian@HIDDEN>) id 1mMI81-0003YL-2R
 for control <at> debbugs.gnu.org; Fri, 03 Sep 2021 18:57:46 -0400
Date: Fri, 03 Sep 2021 15:57:40 -0700
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mgsn.dev; s=key1;
 t=1630709863; h=from:from:reply-to:subject:subject:date:date:to:to:cc;
 bh=fbQ/MKamL2dIGrLyoHYGjyTa3fIVrLRNjlGcPGqBMyM=;
 b=cPqRpuYomYEx3waoT38CisqCspChwJWkzxgCcAE+EndIrTXUCi6xTfSZ/hNiK7PCyAtQjc
 xz3K+eNmd4YNm3vTp4BGBgBmnYks9kd+licMiE7x8SGj2P/38PxQ8v5HCsIzLIyQnkQkaI
 2Js5oyX9RIaWpmPvhaLauKPN9KsMUIg=
To: control <at> debbugs.gnu.org
X-Report-Abuse: Please report any abuse attempt to abuse@HIDDEN and
 include these headers.
From: Sarah Morgensen <iskarian@HIDDEN>
Subject: control message for bug #50363
X-Migadu-Flow: FLOW_OUT
X-Migadu-Auth-User: iskarian@HIDDEN
X-Spam-Score: -0.6 (/)
X-Debbugs-Envelope-To: control
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Message-Id: <E1mMI83-0003YU-Cv <at> debbugs.gnu.org>
X-Spam-Score: -1.7 (-)

retitle 50363 [PATCH] Improve default diff hunk header detection.
quit





Message sent to guix-patches@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: [bug#50363] [PATCH v2] Improve default diff hunk header detection.
Resent-From: Maxime Devos <maximedevos@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: guix-patches@HIDDEN
Resent-Date: Fri, 10 Sep 2021 17:08:02 +0000
Resent-Message-ID: <handler.50363.B50363.163129367726226 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 50363
X-GNU-PR-Package: guix-patches
X-GNU-PR-Keywords: patch
To: Sarah Morgensen <iskarian@HIDDEN>, 50363 <at> debbugs.gnu.org
Received: via spool by 50363-submit <at> debbugs.gnu.org id=B50363.163129367726226
          (code B ref 50363); Fri, 10 Sep 2021 17:08:02 +0000
Received: (at 50363) by debbugs.gnu.org; 10 Sep 2021 17:07:57 +0000
Received: from localhost ([127.0.0.1]:39153 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1mOk0L-0006ov-Hy
	for submit <at> debbugs.gnu.org; Fri, 10 Sep 2021 13:07:57 -0400
Received: from michel.telenet-ops.be ([195.130.137.88]:34018)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <maximedevos@HIDDEN>) id 1mOk0G-0006ok-Tf
 for 50363 <at> debbugs.gnu.org; Fri, 10 Sep 2021 13:07:55 -0400
Received: from [172.20.10.4] ([188.189.169.182])
 by michel.telenet-ops.be with bizsmtp
 id sH7q2500E3wTrX806H7qyk; Fri, 10 Sep 2021 19:07:51 +0200
Message-ID: <02da42c122f4fe839e12a3c8688cc49b140fcb12.camel@HIDDEN>
From: Maxime Devos <maximedevos@HIDDEN>
Date: Fri, 10 Sep 2021 19:07:44 +0200
In-Reply-To: <e6e08312afa17ee812f8b538118bec6da86d3357.1630708121.git.iskarian@HIDDEN>
References: <e6e08312afa17ee812f8b538118bec6da86d3357.1630708121.git.iskarian@HIDDEN>
Content-Type: multipart/signed; micalg="pgp-sha512";
 protocol="application/pgp-signature"; boundary="=-8uzmM/OQoy6a0J2W4eW/"
User-Agent: Evolution 3.34.2 
MIME-Version: 1.0
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telenet.be; s=r21;
 t=1631293671; bh=yNweqsFsaAgeFWh5gA2CjFpAUpOTo3zSL45wNweJo7w=;
 h=Subject:From:To:Date:In-Reply-To:References;
 b=jdWPGTZ7a+UTMrXb6wFNSiSMRVCiSVbAWsvNoHIjS5bxbt562VREOGkOvSwdtLuPl
 MJfDn0rdT2NrBim82Yow9BMCWkv/EtdGXSJR9qHC6EajBVCDjzn7UsozQ4IGYcSjJW
 f749QCGfr6/fPexs0eCYlcAoEKA471Y64A5HB6WdzlSMSThxv75n8RL7ddak/rHr22
 Ehx2PJYKM3oIqoF4SslMlszbQwXAuCJQ2dIOKIKsq7NNDtFNUzh58DepmGv38d7Iwf
 Mohq1dXWWqymusMYz0/XBr8SXTMebXFQ8VL1QjgbgqmAZaPEA9G+408vTrob82tbkY
 J0G1VEQCuZXaw==
X-Spam-Score: -0.7 (/)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.7 (-)


--=-8uzmM/OQoy6a0J2W4eW/
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

Sarah Morgensen schreef op vr 03-09-2021 om 15:39 [-0700]:
> Tell git to look for top-level definitions for diff hunk headers in
> Scheme files.
>=20
> .gitattributes: New file.
> .gitconfig: New file.
> ---
> Hello Guix,
>=20
> This patch improves the diff hunk headers for diffs on scheme files in th=
is
> repository.  These settings are always settable (and overridable) on a
> per-user basis, but I think having them as defaults is nice.
>=20
> This may help with patches applying in general, but the main goal is to m=
ake
> etc/committer.scm a little less brittle.
>
> The default "scheme" function regex (enabled with .gitattributes) recogni=
zes
> both toplevel and non-toplevel defines.  I've modified the regex in .gitc=
onfig
> to only recognize the toplevel defines.  I think this makes more sense fo=
r our
> purposes.
>=20
> Unfortunately, checked-in git config settings cannot be automatically use=
d
> (for security reasons), and must be enabled with a once-per-clone
>=20
>   git config --local include.path ../.gitconfig
>=20
> which isn't ideal.  I suppose we could make a 'make' target for setup lik=
e
> this if we wanted to make it easy.
>=20
> WDYT?

This seems nice to me.
=20
Greetings,
Maxime.

--=-8uzmM/OQoy6a0J2W4eW/
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: This is a digitally signed message part
Content-Transfer-Encoding: 7bit

-----BEGIN PGP SIGNATURE-----

iI0EABYKADUWIQTB8z7iDFKP233XAR9J4+4iGRcl7gUCYTuQ4BccbWF4aW1lZGV2
b3NAdGVsZW5ldC5iZQAKCRBJ4+4iGRcl7sL+AP0XTB0DRfZieAK5bg5AOFScKtyE
MKwCjiqyJC0lkYKdlwEAk0I4q/9EZC/xJ4Pc8psDAe8H9M1x+hOedOuORgnFOgU=
=M7LK
-----END PGP SIGNATURE-----

--=-8uzmM/OQoy6a0J2W4eW/--





Message sent to guix-patches@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: [bug#50363] [PATCH] Improve default diff hunk header detection.
Resent-From: Ludovic =?UTF-8?Q?Court=C3=A8s?= <ludo@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: guix-patches@HIDDEN
Resent-Date: Mon, 13 Sep 2021 10:25:02 +0000
Resent-Message-ID: <handler.50363.B50363.16315286763753 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 50363
X-GNU-PR-Package: guix-patches
X-GNU-PR-Keywords: patch
To: Sarah Morgensen <iskarian@HIDDEN>
Cc: 50363 <at> debbugs.gnu.org
Received: via spool by 50363-submit <at> debbugs.gnu.org id=B50363.16315286763753
          (code B ref 50363); Mon, 13 Sep 2021 10:25:02 +0000
Received: (at 50363) by debbugs.gnu.org; 13 Sep 2021 10:24:36 +0000
Received: from localhost ([127.0.0.1]:44450 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1mPj8d-0000yT-UE
	for submit <at> debbugs.gnu.org; Mon, 13 Sep 2021 06:24:36 -0400
Received: from eggs.gnu.org ([209.51.188.92]:33954)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <ludo@HIDDEN>) id 1mPj8c-0000yE-4T
 for 50363 <at> debbugs.gnu.org; Mon, 13 Sep 2021 06:24:34 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:60114)
 by eggs.gnu.org with esmtp (Exim 4.90_1)
 (envelope-from <ludo@HIDDEN>)
 id 1mPj8W-0001OF-Rc; Mon, 13 Sep 2021 06:24:28 -0400
Received: from [2001:660:6102:320:e120:2c8f:8909:cdfe] (port=47250 helo=ribbon)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <ludo@HIDDEN>)
 id 1mPj8W-00013n-It; Mon, 13 Sep 2021 06:24:28 -0400
From: Ludovic =?UTF-8?Q?Court=C3=A8s?= <ludo@HIDDEN>
References: <e6e08312afa17ee812f8b538118bec6da86d3357.1630708121.git.iskarian@HIDDEN>
Date: Mon, 13 Sep 2021 12:24:25 +0200
In-Reply-To: <e6e08312afa17ee812f8b538118bec6da86d3357.1630708121.git.iskarian@HIDDEN>
 (Sarah Morgensen's message of "Fri, 3 Sep 2021 15:39:05 -0700")
Message-ID: <87czpcai3q.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
X-Spam-Score: -2.3 (--)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

Hi!

Sarah Morgensen <iskarian@HIDDEN> skribis:

> Tell git to look for top-level definitions for diff hunk headers in
> Scheme files.
>
> .gitattributes: New file.
> .gitconfig: New file.
> ---
> Hello Guix,
>
> This patch improves the diff hunk headers for diffs on scheme files in th=
is
> repository.  These settings are always settable (and overridable) on a
> per-user basis, but I think having them as defaults is nice.
>
> This may help with patches applying in general, but the main goal is to m=
ake
> etc/committer.scm a little less brittle.
>
> The default "scheme" function regex (enabled with .gitattributes) recogni=
zes
> both toplevel and non-toplevel defines.  I've modified the regex in .gitc=
onfig
> to only recognize the toplevel defines.  I think this makes more sense fo=
r our
> purposes.
>
> Unfortunately, checked-in git config settings cannot be automatically used
> (for security reasons), and must be enabled with a once-per-clone
>
>   git config --local include.path ../.gitconfig
>
> which isn't ideal.  I suppose we could make a 'make' target for setup like
> this if we wanted to make it easy.
>
> WDYT?

That LGTM too.  Rather than a =E2=80=98make=E2=80=99 target, how about a ad=
ding a line
or two under =E2=80=9CContributing=E2=80=9D?

Thanks,
Ludo=E2=80=99.




Message sent to guix-patches@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: [bug#50363] [PATCH v3] Improve default diff hunk header detection.
Resent-From: Sarah Morgensen <iskarian@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: guix-patches@HIDDEN
Resent-Date: Sun, 19 Sep 2021 18:37:02 +0000
Resent-Message-ID: <handler.50363.B50363.163207660923685 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 50363
X-GNU-PR-Package: guix-patches
X-GNU-PR-Keywords: patch
To: 50363 <at> debbugs.gnu.org
Cc: ludo@HIDDEN, maximedevos@HIDDEN
Received: via spool by 50363-submit <at> debbugs.gnu.org id=B50363.163207660923685
          (code B ref 50363); Sun, 19 Sep 2021 18:37:02 +0000
Received: (at 50363) by debbugs.gnu.org; 19 Sep 2021 18:36:49 +0000
Received: from localhost ([127.0.0.1]:39940 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1mS1gH-00069x-Cr
	for submit <at> debbugs.gnu.org; Sun, 19 Sep 2021 14:36:49 -0400
Received: from out0.migadu.com ([94.23.1.103]:52179)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <iskarian@HIDDEN>) id 1mS1gE-00069n-PF
 for 50363 <at> debbugs.gnu.org; Sun, 19 Sep 2021 14:36:48 -0400
X-Report-Abuse: Please report any abuse attempt to abuse@HIDDEN and
 include these headers.
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mgsn.dev; s=key1;
 t=1632076605;
 h=from:from:reply-to:subject:subject:date:date:message-id:message-id:
 to:to:cc:cc:mime-version:mime-version:
 content-transfer-encoding:content-transfer-encoding:
 in-reply-to:in-reply-to:references:references;
 bh=PoAhtwiVR1r6L97YWFzO58zEw1DqC7PRqdCUL7NZTbI=;
 b=C3vBjZR/kSBTUBmKlEBAU1rUC+yDwierJJKwLzm6HAUFlrTaiHVxFDaxLymUcl3bcByNYq
 xf8sRv5FlV5fJJP0pL8u3N1wb+t9xPtrKt0tUKwxwYsVKv/ElfoYqMGTyHi5/bzTxoN/7A
 jy5cXOPcFlYZszrp6qz9qrF2QP1J7ro=
From: Sarah Morgensen <iskarian@HIDDEN>
Date: Sun, 19 Sep 2021 11:36:43 -0700
Message-Id: <58187bb9c61bc7599cde31b52a5dd58e90c1f78f.1632076068.git.iskarian@HIDDEN>
In-Reply-To: <e6e08312afa17ee812f8b538118bec6da86d3357.1630708121.git.iskarian@HIDDEN>
References: <e6e08312afa17ee812f8b538118bec6da86d3357.1630708121.git.iskarian@HIDDEN>
MIME-Version: 1.0
Content-Transfer-Encoding: 8bit
X-Migadu-Flow: FLOW_OUT
X-Migadu-Auth-User: iskarian@HIDDEN
X-Spam-Score: -0.7 (/)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.7 (-)

Tell git where to look for diff hunk headers: top-level definitions for
Scheme files, and (sub)section headers for texi files.

* .gitattributes, etc/git/gitconfig: New files.
* doc/contributing.texi ("Submitting Patches"): Add subsection
"Configuring Git".  Document etc/git/gitconfig.
---
Changes from previous version:

* Added rule for .texi files

* Documented how to use the advanced settings in the manual (as well as some
  other related information)

Note that I am currently working on a rewrite of "Submitting Patches", so
"Configuring Git" will eventually get its own proper subsection.

--
Sarah
 .gitattributes        |  3 +++
 doc/contributing.texi | 46 +++++++++++++++++++++++++++++++++++++++----
 doc/guix.texi         |  1 +
 etc/git/gitconfig     |  5 +++++
 4 files changed, 51 insertions(+), 4 deletions(-)
 create mode 100644 .gitattributes
 create mode 100644 etc/git/gitconfig

diff --git a/.gitattributes b/.gitattributes
new file mode 100644
index 0000000000..51f29b8a48
--- /dev/null
+++ b/.gitattributes
@@ -0,0 +1,3 @@
+*.scm       diff=scheme
+*.scm.in    diff=scheme
+*.texi      diff=tex
diff --git a/doc/contributing.texi b/doc/contributing.texi
index d1b77d7d05..0e8747ab25 100644
--- a/doc/contributing.texi
+++ b/doc/contributing.texi
@@ -992,9 +992,12 @@ @section Submitting Patches
 Development is done using the Git distributed version control system.
 Thus, access to the repository is not strictly necessary.  We welcome
 contributions in the form of patches as produced by @code{git
-format-patch} sent to the @email{guix-patches@@gnu.org} mailing list.
-Seasoned Guix developers may also want to look at the section on commit
-access (@pxref{Commit Access}).
+format-patch} sent to the @email{guix-patches@@gnu.org} mailing list
+(@pxref{submitting patches,, Submitting patches to a project, git, Git
+User Manual}).  Contributors are encouraged to take a moment to set some
+Git repository options (@pxref{Configuring Git}) first, which can
+improve the readability of patches.  Seasoned Guix developers may also
+want to look at the section on commit access (@pxref{Commit Access}).
 
 This mailing list is backed by a Debbugs instance, which allows us to
 keep track of submissions (@pxref{Tracking Bugs and Patches}).  Each
@@ -1205,11 +1208,46 @@ @section Submitting Patches
 When a bug is resolved, please close the thread by sending an email to
 @email{@var{NNN}-done@@debbugs.gnu.org}.
 
+@node Configuring Git
+@subsection Configuring Git
+@cindex git configuration
+@cindex @code{git format-patch}
+@cindex @code{git send-email}
+
+If you have not done so already, you may wish to set a name and email
+that will be associated with your commits (@pxref{telling git your name,
+, Telling Git your name, git, Git User Manual}).  If you wish to use a
+different name or email just for commits in this respository, you can
+use @command{git config --local}, or edit @file{.git/config} in the
+repository instead of @file{~/.gitconfig}.
+
+We provide some default settings in @file{etc/git/gitconfig} which
+modify how patches are generated, making them easier to read and apply.
+These settings can be applied by manually copying them to
+@file{.git/config} in your checkout, or by telling Git to include the
+whole file:
+
+@example
+git config --local include.path=../etc/git/gitconfig
+@end example
+
+From then on, any changes to @file{etc/git/gitconfig} would
+automatically take effect.
+
+Since the first patch in a series must be sent separately
+(@pxref{Sending a Patch Series}), it can also be helpful to tell
+@command{git format-patch} to handle the e-mail threading instead of
+@command{git send-email}:
+
+@example
+git config --local format.thread=shallow
+git config --local sendemail.thread=no
+@end example
+
 @unnumberedsubsec Sending a Patch Series
 @anchor{Sending a Patch Series}
 @cindex patch series
 @cindex @code{git send-email}
-@cindex @code{git-send-email}
 
 When sending a patch series (e.g., using @code{git send-email}), please
 first send one message to @email{guix-patches@@gnu.org}, and then send
diff --git a/doc/guix.texi b/doc/guix.texi
index 6436e83a7c..4dac36310f 100644
--- a/doc/guix.texi
+++ b/doc/guix.texi
@@ -96,6 +96,7 @@
 Copyright @copyright{} 2021 Hui Lu@*
 Copyright @copyright{} 2021 pukkamustard@*
 Copyright @copyright{} 2021 Alice Brenon@*
+Copyright @copyright{} 2021 Sarah Morgensen@*
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.3 or
diff --git a/etc/git/gitconfig b/etc/git/gitconfig
new file mode 100644
index 0000000000..290006816f
--- /dev/null
+++ b/etc/git/gitconfig
@@ -0,0 +1,5 @@
+[diff "scheme"]
+	xfuncname = "^(\\(define.*)$"
+
+[diff "tex"]
+	xfuncname = "^(@((|sub|subsub)section|(unnumbered|appendix)((|sub|subsub)sec)|(|major|chap|sub|subsub)heading|chapter|part|titlepage|top)[ \t]+.*)$"

base-commit: 808f9ffbd3106da4c92d2367b118b98196c9e81e
-- 
2.33.0





Message sent to guix-patches@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: [bug#50363] [PATCH v3] Improve default diff hunk header detection.
Resent-From: Kyle Meyer <kyle@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: guix-patches@HIDDEN
Resent-Date: Sun, 19 Sep 2021 22:10:01 +0000
Resent-Message-ID: <handler.50363.B50363.163208940111903 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 50363
X-GNU-PR-Package: guix-patches
X-GNU-PR-Keywords: patch
To: Sarah Morgensen <iskarian@HIDDEN>
Cc: 50363 <at> debbugs.gnu.org, ludo@HIDDEN, maximedevos@HIDDEN
Received: via spool by 50363-submit <at> debbugs.gnu.org id=B50363.163208940111903
          (code B ref 50363); Sun, 19 Sep 2021 22:10:01 +0000
Received: (at 50363) by debbugs.gnu.org; 19 Sep 2021 22:10:01 +0000
Received: from localhost ([127.0.0.1]:40183 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1mS50a-00035v-MX
	for submit <at> debbugs.gnu.org; Sun, 19 Sep 2021 18:10:00 -0400
Received: from out2.migadu.com ([188.165.223.204]:21500)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <kyle@HIDDEN>) id 1mS50X-00035l-QW
 for 50363 <at> debbugs.gnu.org; Sun, 19 Sep 2021 18:09:59 -0400
X-Report-Abuse: Please report any abuse attempt to abuse@HIDDEN and
 include these headers.
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kyleam.com; s=key1;
 t=1632089396;
 h=from:from:reply-to:subject:subject:date:date:message-id:message-id:
 to:to:cc:cc:mime-version:mime-version:content-type:content-type:
 in-reply-to:in-reply-to:references:references;
 bh=aaXyqbT6c8vz6tWswZjAJvtGEqpHhaFHI9BwCKx12AE=;
 b=ezsVH36c8VwIuHw4P8Pzb5zKp0Pytm8AwWpihc06W3Qa5XciBsTEY+Av3W68IXgXFxHCCC
 f6PPCQ4MVst9H4BG0L9rWwEdCJdgFxR/reIyndbH174G5jOZuMu0C7d4X7QJ2qzG/cXmO5
 PxMecyJ0CRe+0dBchlv8a44qsCO+ItxprK2WcySIWSk5MaG7RAya8PMS2h/WFvtlbXME2r
 BSBim+LCLZVyey+sCVJsKaD3Db39jyt4HTBWWYDhZpDmLO9yRjR0z8Ul+UIdgUApl73k5z
 RaBUZJCsAiiABVuPItJ+uK3DFJvKON7EbLm69shnTQju7HAIy+ghduPIo3CsIg==
From: Kyle Meyer <kyle@HIDDEN>
In-Reply-To: <58187bb9c61bc7599cde31b52a5dd58e90c1f78f.1632076068.git.iskarian@HIDDEN>
References: <e6e08312afa17ee812f8b538118bec6da86d3357.1630708121.git.iskarian@HIDDEN>
 <58187bb9c61bc7599cde31b52a5dd58e90c1f78f.1632076068.git.iskarian@HIDDEN>
Date: Sun, 19 Sep 2021 18:09:47 -0400
Message-ID: <87o88o8bf8.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: text/plain
X-Migadu-Flow: FLOW_OUT
X-Migadu-Auth-User: kyle@HIDDEN
X-Spam-Score: -0.0 (/)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Sarah Morgensen writes:

> diff --git a/.gitattributes b/.gitattributes
> new file mode 100644
> index 0000000000..51f29b8a48
> --- /dev/null
> +++ b/.gitattributes
> @@ -0,0 +1,3 @@
> +*.scm       diff=scheme
> +*.scm.in    diff=scheme
> +*.texi      diff=tex

"tex" is a built-in pattern for LaTeX.  To avoid confusion, I suggest
"texinfo", which is what the Emacs repo uses.

> diff --git a/doc/contributing.texi b/doc/contributing.texi
[...]
> +@example
> +git config --local include.path=../etc/git/gitconfig
> +@end example

The '=' above should be a space:

  $ git config --local include.path=../etc/git/gitconfig
  error: invalid key: include.path=../etc/git/gitconfig

(This is true in the other examples as well.)

Just thinking aloud: the include.path approach above assumes a clone
with the standard $GIT_DIR and working tree layout, but that seems fine
because users with more unusual setups would know how to adjust it for
their case.  Also, for git-worktree users, the etc/git/gitconfig file in
the main worktree would be used within other worktrees, but for this use
case I doubt that will cause confusion.

>  @unnumberedsubsec Sending a Patch Series
>  @anchor{Sending a Patch Series}
>  @cindex patch series
>  @cindex @code{git send-email}
> -@cindex @code{git-send-email}

I suspect the second variant was included to help those that are using
the git- variant to search (perhaps because that's how they'd refer to
the manpage or because they know about Git's exec path).  Not a big deal
either way, but keeping it around seems okay to me.

> diff --git a/etc/git/gitconfig b/etc/git/gitconfig
> new file mode 100644
> index 0000000000..290006816f
> --- /dev/null
> +++ b/etc/git/gitconfig
> @@ -0,0 +1,5 @@
> +[diff "scheme"]
> +	xfuncname = "^(\\(define.*)$"
> +
> +[diff "tex"]
> +	xfuncname = "^(@((|sub|subsub)section|(unnumbered|appendix)((|sub|subsub)sec)|(|major|chap|sub|subsub)heading|chapter|part|titlepage|top)[ \t]+.*)$"

Fwiw the Emacs repo sets a simpler value (via autogen.sh):

  ^@node[[:space:]]+([^,[:space:]][^,]+)




Message sent to guix-patches@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: [bug#50363] [PATCH v3] Improve default diff hunk header detection.
Resent-From: Sarah Morgensen <iskarian@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: guix-patches@HIDDEN
Resent-Date: Sun, 19 Sep 2021 22:57:01 +0000
Resent-Message-ID: <handler.50363.B50363.163209221516462 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 50363
X-GNU-PR-Package: guix-patches
X-GNU-PR-Keywords: patch
To: Kyle Meyer <kyle@HIDDEN>
Cc: 50363 <at> debbugs.gnu.org, ludo@HIDDEN, maximedevos@HIDDEN
Received: via spool by 50363-submit <at> debbugs.gnu.org id=B50363.163209221516462
          (code B ref 50363); Sun, 19 Sep 2021 22:57:01 +0000
Received: (at 50363) by debbugs.gnu.org; 19 Sep 2021 22:56:55 +0000
Received: from localhost ([127.0.0.1]:40250 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1mS5jz-0004HS-Dd
	for submit <at> debbugs.gnu.org; Sun, 19 Sep 2021 18:56:55 -0400
Received: from out2.migadu.com ([188.165.223.204]:33663)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <iskarian@HIDDEN>) id 1mS5jw-0004HI-Do
 for 50363 <at> debbugs.gnu.org; Sun, 19 Sep 2021 18:56:54 -0400
X-Report-Abuse: Please report any abuse attempt to abuse@HIDDEN and
 include these headers.
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mgsn.dev; s=key1;
 t=1632092210;
 h=from:from:reply-to:subject:subject:date:date:message-id:message-id:
 to:to:cc:cc:mime-version:mime-version:content-type:content-type:
 in-reply-to:in-reply-to:references:references;
 bh=mjPYkoxXE+LKBDfaG6ZEdELZ88F5MY+W+zq1sHtCtDo=;
 b=epLAnPmQ2DZcDqzuSiHvoL7+sT9nD+D3w+WSD+mfcuKYf4+aNSBPNoVfMcjxdPOPVBkuxW
 J+whwWOWTvOwtF3V4P9v0ixVoVgZc9d95KgHt9yoCTk5qP8mIlT7H4IL/5sTxJYWaDRuOJ
 xCk7gNldAt9bMnMqbVEXTScaI65vhao=
From: Sarah Morgensen <iskarian@HIDDEN>
References: <e6e08312afa17ee812f8b538118bec6da86d3357.1630708121.git.iskarian@HIDDEN>
 <58187bb9c61bc7599cde31b52a5dd58e90c1f78f.1632076068.git.iskarian@HIDDEN>
 <87o88o8bf8.fsf@HIDDEN>
Date: Sun, 19 Sep 2021 15:56:43 -0700
In-Reply-To: <87o88o8bf8.fsf@HIDDEN> (Kyle Meyer's message of "Sun, 19 Sep
 2021 18:09:47 -0400 (21 minutes, 1 second ago)")
Message-ID: <86ee9kgono.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: text/plain
X-Migadu-Flow: FLOW_OUT
X-Migadu-Auth-User: iskarian@HIDDEN
X-Spam-Score: -0.0 (/)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Hello Kyle,

Thanks for taking a look and trying this out!

Kyle Meyer <kyle@HIDDEN> writes:

> Sarah Morgensen writes:
>
>> diff --git a/.gitattributes b/.gitattributes
>> new file mode 100644
>> index 0000000000..51f29b8a48
>> --- /dev/null
>> +++ b/.gitattributes
>> @@ -0,0 +1,3 @@
>> +*.scm       diff=scheme
>> +*.scm.in    diff=scheme
>> +*.texi      diff=tex
>
> "tex" is a built-in pattern for LaTeX.  To avoid confusion, I suggest
> "texinfo", which is what the Emacs repo uses.

Good point.  I was trying to use the built-in because it has a
whitespace regex defined in userdiff.c, but I just found that I can set
that with wordRegex, so I'll do that.  I'll take a look at the Emacs
repo as well.

>
>> diff --git a/doc/contributing.texi b/doc/contributing.texi
> [...]
>> +@example
>> +git config --local include.path=../etc/git/gitconfig
>> +@end example
>
> The '=' above should be a space:
>
>   $ git config --local include.path=../etc/git/gitconfig
>   error: invalid key: include.path=../etc/git/gitconfig
>
> (This is true in the other examples as well.)

Thanks for catching this.

>
> Just thinking aloud: the include.path approach above assumes a clone
> with the standard $GIT_DIR and working tree layout, but that seems fine
> because users with more unusual setups would know how to adjust it for
> their case.  Also, for git-worktree users, the etc/git/gitconfig file in
> the main worktree would be used within other worktrees, but for this use
> case I doubt that will cause confusion.

I actually wrote about the worktree limitation at first, but I thought
including it would be more confusing to people who don't use them than
it would be helpful to people who do.

>>  @unnumberedsubsec Sending a Patch Series
>>  @anchor{Sending a Patch Series}
>>  @cindex patch series
>>  @cindex @code{git send-email}
>> -@cindex @code{git-send-email}
>
> I suspect the second variant was included to help those that are using
> the git- variant to search (perhaps because that's how they'd refer to
> the manpage or because they know about Git's exec path).  Not a big deal
> either way, but keeping it around seems okay to me.

Hmmm.  I originally removed it because it results in two entries in the
index.  Perhaps I can index them as

  @cindex @code{git send-email} (or @code{git-send-email})

or similar.  What do you think?

>> diff --git a/etc/git/gitconfig b/etc/git/gitconfig
>> new file mode 100644
>> index 0000000000..290006816f
>> --- /dev/null
>> +++ b/etc/git/gitconfig
>> @@ -0,0 +1,5 @@
>> +[diff "scheme"]
>> +	xfuncname = "^(\\(define.*)$"
>> +
>> +[diff "tex"]
>> +	xfuncname = "^(@((|sub|subsub)section|(unnumbered|appendix)((|sub|subsub)sec)|(|major|chap|sub|subsub)heading|chapter|part|titlepage|top)[ \t]+.*)$"
>
> Fwiw the Emacs repo sets a simpler value (via autogen.sh):
>
>   ^@node[[:space:]]+([^,[:space:]][^,]+)

I made this choice because we have several unnumbered subsections
without nodes that are fairly long.  Otherwise, nodes make a good
choice.

Also, their xfuncname will only show the node name as the diff hunk
header--not the whole line.  I also considered this (I think it's
cleaner) but I thought it might be confusing.  If others like it, let's
do it.

--
Sarah




Message sent to guix-patches@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: [bug#50363] [PATCH v3] Improve default diff hunk header detection.
Resent-From: Kyle Meyer <kyle@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: guix-patches@HIDDEN
Resent-Date: Mon, 20 Sep 2021 00:59:01 +0000
Resent-Message-ID: <handler.50363.B50363.16320994873492 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 50363
X-GNU-PR-Package: guix-patches
X-GNU-PR-Keywords: patch
To: Sarah Morgensen <iskarian@HIDDEN>
Cc: 50363 <at> debbugs.gnu.org, ludo@HIDDEN, maximedevos@HIDDEN
Received: via spool by 50363-submit <at> debbugs.gnu.org id=B50363.16320994873492
          (code B ref 50363); Mon, 20 Sep 2021 00:59:01 +0000
Received: (at 50363) by debbugs.gnu.org; 20 Sep 2021 00:58:07 +0000
Received: from localhost ([127.0.0.1]:40336 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1mS7dG-0000uF-Nn
	for submit <at> debbugs.gnu.org; Sun, 19 Sep 2021 20:58:06 -0400
Received: from out1.migadu.com ([91.121.223.63]:61377)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <kyle@HIDDEN>) id 1mS7dD-0000u5-8N
 for 50363 <at> debbugs.gnu.org; Sun, 19 Sep 2021 20:58:04 -0400
X-Report-Abuse: Please report any abuse attempt to abuse@HIDDEN and
 include these headers.
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kyleam.com; s=key1;
 t=1632099481;
 h=from:from:reply-to:subject:subject:date:date:message-id:message-id:
 to:to:cc:cc:mime-version:mime-version:content-type:content-type:
 in-reply-to:in-reply-to:references:references;
 bh=rUHxZGzGIls1tdFhWAeGsatNm9NBTv/EDlIZ+Day3rM=;
 b=wX+RM0ts05BWy+iaX6q70OuZm3g6ghI+TejXtUjje7VWXNV81rqrDUCP6Eic/w3n9lPxex
 QsSPH61qKI/CnBaT2IzXGGdYt63CoYOFc+FOvE8psoseeZtwz3wSUXsNJv5Rys8jXNyIwZ
 +Rt7B+GTuyC1TR4fZ7EntoL/jUOJ9i1C0td+ib+BkdEQpQDjUIEFBEXoeKH+bb24PtOOuO
 mkC1CZNOCpB0SNyb/rYu1b8vkF3soeemAfHHxu3yYCJSPX/DYIEdPs/M7FBe7Fup8RcDzR
 Nz2cOsfz1MDCJe2b6Fa7w+0Jouu5pi4AIy2Q65Ew++VUiWkAXK7J4/EmBFChOQ==
From: Kyle Meyer <kyle@HIDDEN>
In-Reply-To: <86ee9kgono.fsf@HIDDEN>
References: <e6e08312afa17ee812f8b538118bec6da86d3357.1630708121.git.iskarian@HIDDEN>
 <58187bb9c61bc7599cde31b52a5dd58e90c1f78f.1632076068.git.iskarian@HIDDEN>
 <87o88o8bf8.fsf@HIDDEN> <86ee9kgono.fsf@HIDDEN>
Date: Sun, 19 Sep 2021 20:57:53 -0400
Message-ID: <87k0jc83n2.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: text/plain
X-Migadu-Flow: FLOW_OUT
X-Migadu-Auth-User: kyle@HIDDEN
X-Spam-Score: -0.7 (/)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.7 (-)

Sarah Morgensen writes:

> Kyle Meyer <kyle@HIDDEN> writes:
>
>> Sarah Morgensen writes:
[...]
>>>  @cindex @code{git send-email}
>>> -@cindex @code{git-send-email}
>>
>> I suspect the second variant was included to help those that are using
>> the git- variant to search (perhaps because that's how they'd refer to
>> the manpage or because they know about Git's exec path).  Not a big deal
>> either way, but keeping it around seems okay to me.
>
> Hmmm.  I originally removed it because it results in two entries in the
> index.  Perhaps I can index them as
>
>   @cindex @code{git send-email} (or @code{git-send-email})
>
> or similar.  What do you think?

I don't see having entries in the index for different variants as an
issue (although I can see the point of view that it's just noise in this
case).  As for packing them into one line, dunno, think I'd just leave
it either as it is (separate lines) or how your patch has it.

But, again, I don't think it matters much either way (and perhaps wasn't
worth me commenting on it :]).




Message sent to guix-patches@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: [bug#50363] [PATCH v4] Improve default diff hunk header detection.
Resent-From: Sarah Morgensen <iskarian@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: guix-patches@HIDDEN
Resent-Date: Mon, 20 Sep 2021 23:38:01 +0000
Resent-Message-ID: <handler.50363.B50363.163218107711743 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 50363
X-GNU-PR-Package: guix-patches
X-GNU-PR-Keywords: patch
To: 50363 <at> debbugs.gnu.org
Cc: ludo@HIDDEN, maximedevos@HIDDEN, kyle@HIDDEN
Received: via spool by 50363-submit <at> debbugs.gnu.org id=B50363.163218107711743
          (code B ref 50363); Mon, 20 Sep 2021 23:38:01 +0000
Received: (at 50363) by debbugs.gnu.org; 20 Sep 2021 23:37:57 +0000
Received: from localhost ([127.0.0.1]:44299 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1mSSrE-00033K-Hp
	for submit <at> debbugs.gnu.org; Mon, 20 Sep 2021 19:37:57 -0400
Received: from out2.migadu.com ([188.165.223.204]:45122)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <iskarian@HIDDEN>) id 1mSSrC-00033B-4Y
 for 50363 <at> debbugs.gnu.org; Mon, 20 Sep 2021 19:37:55 -0400
X-Report-Abuse: Please report any abuse attempt to abuse@HIDDEN and
 include these headers.
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mgsn.dev; s=key1;
 t=1632181072;
 h=from:from:reply-to:subject:subject:date:date:message-id:message-id:
 to:to:cc:cc:mime-version:mime-version:
 content-transfer-encoding:content-transfer-encoding:
 in-reply-to:in-reply-to:references:references;
 bh=NC1cTB41VF5atrk8Adb8gh8Mmlw994MMYjXHeoCSjyk=;
 b=bClkc/vQPJEDvAsf8k430pJviY9h2/X5C/sr5EBglOeGn3l3+spzYq2jxcW5UyGYH+S9Z/
 yS7TcE0AaWVuKVzWdZHwGk9H4NWavSqgAdE0k3ibzmzG7x72PUu42DWNifMfdB0lmKmPNj
 A1UzzNhutyH3szhUjoR0FGNG/K/aU1g=
From: Sarah Morgensen <iskarian@HIDDEN>
Date: Mon, 20 Sep 2021 16:37:44 -0700
Message-Id: <bbac973c0d0388fabe126bd44b60b0683ffe9f03.1632180690.git.iskarian@HIDDEN>
In-Reply-To: <e6e08312afa17ee812f8b538118bec6da86d3357.1630708121.git.iskarian@HIDDEN>
References: <e6e08312afa17ee812f8b538118bec6da86d3357.1630708121.git.iskarian@HIDDEN>
MIME-Version: 1.0
Content-Transfer-Encoding: 8bit
X-Migadu-Flow: FLOW_OUT
X-Migadu-Auth-User: iskarian@HIDDEN
X-Spam-Score: -0.0 (/)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Tell git where to look for diff hunk headers: top-level definitions for
Scheme files, and (sub)section headers for texi files.

* .gitattributes, etc/git/gitconfig: New files.
* doc/contributing.texi ("Submitting Patches"): Add subsection
"Configuring Git".  Document etc/git/gitconfig.
---
Changes since v3 (thanks to Kyle for the suggestions):

* Diff name changed from "tex" to "texinfo"

* "texinfo" diff matches nodes rather than sections (this is what most
texinfo diff drivers seem to do)

* Examples fixed

--
 .gitattributes        |  3 +++
 doc/contributing.texi | 46 +++++++++++++++++++++++++++++++++++++++----
 doc/guix.texi         |  1 +
 etc/git/gitconfig     |  5 +++++
 4 files changed, 51 insertions(+), 4 deletions(-)
 create mode 100644 .gitattributes
 create mode 100644 etc/git/gitconfig

diff --git a/.gitattributes b/.gitattributes
new file mode 100644
index 0000000000..b31f7fd74d
--- /dev/null
+++ b/.gitattributes
@@ -0,0 +1,3 @@
+*.scm       diff=scheme
+*.scm.in    diff=scheme
+*.texi      diff=texinfo
diff --git a/doc/contributing.texi b/doc/contributing.texi
index d1b77d7d05..a6bfcb82e0 100644
--- a/doc/contributing.texi
+++ b/doc/contributing.texi
@@ -992,9 +992,12 @@ Submitting Patches
 Development is done using the Git distributed version control system.
 Thus, access to the repository is not strictly necessary.  We welcome
 contributions in the form of patches as produced by @code{git
-format-patch} sent to the @email{guix-patches@@gnu.org} mailing list.
-Seasoned Guix developers may also want to look at the section on commit
-access (@pxref{Commit Access}).
+format-patch} sent to the @email{guix-patches@@gnu.org} mailing list
+(@pxref{submitting patches,, Submitting patches to a project, git, Git
+User Manual}).  Contributors are encouraged to take a moment to set some
+Git repository options (@pxref{Configuring Git}) first, which can
+improve the readability of patches.  Seasoned Guix developers may also
+want to look at the section on commit access (@pxref{Commit Access}).
 
 This mailing list is backed by a Debbugs instance, which allows us to
 keep track of submissions (@pxref{Tracking Bugs and Patches}).  Each
@@ -1205,11 +1208,46 @@ Submitting Patches
 When a bug is resolved, please close the thread by sending an email to
 @email{@var{NNN}-done@@debbugs.gnu.org}.
 
+@node Configuring Git
+@subsection Configuring Git
+@cindex git configuration
+@cindex @code{git format-patch}
+@cindex @code{git send-email}
+
+If you have not done so already, you may wish to set a name and email
+that will be associated with your commits (@pxref{telling git your name,
+, Telling Git your name, git, Git User Manual}).  If you wish to use a
+different name or email just for commits in this respository, you can
+use @command{git config --local}, or edit @file{.git/config} in the
+repository instead of @file{~/.gitconfig}.
+
+We provide some default settings in @file{etc/git/gitconfig} which
+modify how patches are generated, making them easier to read and apply.
+These settings can be applied by manually copying them to
+@file{.git/config} in your checkout, or by telling Git to include the
+whole file:
+
+@example
+git config --local include.path ../etc/git/gitconfig
+@end example
+
+From then on, any changes to @file{etc/git/gitconfig} would
+automatically take effect.
+
+Since the first patch in a series must be sent separately
+(@pxref{Sending a Patch Series}), it can also be helpful to tell
+@command{git format-patch} to handle the e-mail threading instead of
+@command{git send-email}:
+
+@example
+git config --local format.thread shallow
+git config --local sendemail.thread no
+@end example
+
 @unnumberedsubsec Sending a Patch Series
 @anchor{Sending a Patch Series}
 @cindex patch series
 @cindex @code{git send-email}
-@cindex @code{git-send-email}
 
 When sending a patch series (e.g., using @code{git send-email}), please
 first send one message to @email{guix-patches@@gnu.org}, and then send
diff --git a/doc/guix.texi b/doc/guix.texi
index 6436e83a7c..4dac36310f 100644
--- a/doc/guix.texi
+++ b/doc/guix.texi
@@ -96,6 +96,7 @@
 Copyright @copyright{} 2021 Hui Lu@*
 Copyright @copyright{} 2021 pukkamustard@*
 Copyright @copyright{} 2021 Alice Brenon@*
+Copyright @copyright{} 2021 Sarah Morgensen@*
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.3 or
diff --git a/etc/git/gitconfig b/etc/git/gitconfig
new file mode 100644
index 0000000000..c9ebdc8fa8
--- /dev/null
+++ b/etc/git/gitconfig
@@ -0,0 +1,5 @@
+[diff "scheme"]
+	xfuncname = "^(\\(define.*)$"
+
+[diff "texinfo"]
+	xfuncname = "^@node[[:space:]]+([^,]+).*$"

base-commit: 808f9ffbd3106da4c92d2367b118b98196c9e81e
-- 
2.33.0





Message sent to guix-patches@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: [bug#50363] [PATCH v4] Improve default diff hunk header detection.
Resent-From: Ludovic =?UTF-8?Q?Court=C3=A8s?= <ludo@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: guix-patches@HIDDEN
Resent-Date: Wed, 22 Sep 2021 12:56:02 +0000
Resent-Message-ID: <handler.50363.B50363.163231533823702 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 50363
X-GNU-PR-Package: guix-patches
X-GNU-PR-Keywords: patch
To: Sarah Morgensen <iskarian@HIDDEN>
Cc: 50363 <at> debbugs.gnu.org, kyle@HIDDEN, maximedevos@HIDDEN
Received: via spool by 50363-submit <at> debbugs.gnu.org id=B50363.163231533823702
          (code B ref 50363); Wed, 22 Sep 2021 12:56:02 +0000
Received: (at 50363) by debbugs.gnu.org; 22 Sep 2021 12:55:38 +0000
Received: from localhost ([127.0.0.1]:49040 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1mT1mk-0006AE-Br
	for submit <at> debbugs.gnu.org; Wed, 22 Sep 2021 08:55:38 -0400
Received: from eggs.gnu.org ([209.51.188.92]:56834)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <ludo@HIDDEN>) id 1mT1mh-00069q-8s
 for 50363 <at> debbugs.gnu.org; Wed, 22 Sep 2021 08:55:37 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:33630)
 by eggs.gnu.org with esmtp (Exim 4.90_1)
 (envelope-from <ludo@HIDDEN>)
 id 1mT1ma-0000el-UI; Wed, 22 Sep 2021 08:55:28 -0400
Received: from [2a01:e0a:1d:7270:af76:b9b:ca24:c465] (port=35978 helo=ribbon)
 by fencepost.gnu.org with esmtpsa
 (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1)
 (envelope-from <ludo@HIDDEN>)
 id 1mT1ma-0001Bz-BK; Wed, 22 Sep 2021 08:55:28 -0400
From: Ludovic =?UTF-8?Q?Court=C3=A8s?= <ludo@HIDDEN>
References: <e6e08312afa17ee812f8b538118bec6da86d3357.1630708121.git.iskarian@HIDDEN>
 <bbac973c0d0388fabe126bd44b60b0683ffe9f03.1632180690.git.iskarian@HIDDEN>
X-URL: http://www.fdn.fr/~lcourtes/
X-Revolutionary-Date: 1 =?UTF-8?Q?Vend=C3=A9miaire?= an 230 de la
 =?UTF-8?Q?R=C3=A9volution?=
X-PGP-Key-ID: 0x090B11993D9AEBB5
X-PGP-Key: http://www.fdn.fr/~lcourtes/ludovic.asc
X-PGP-Fingerprint: 3CE4 6455 8A84 FDC6 9DB4  0CFB 090B 1199 3D9A EBB5
X-OS: x86_64-pc-linux-gnu
Date: Wed, 22 Sep 2021 14:55:26 +0200
In-Reply-To: <bbac973c0d0388fabe126bd44b60b0683ffe9f03.1632180690.git.iskarian@HIDDEN>
 (Sarah Morgensen's message of "Mon, 20 Sep 2021 16:37:44 -0700")
Message-ID: <87o88khirl.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
X-Spam-Score: -2.3 (--)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

Hi,

Sarah Morgensen <iskarian@HIDDEN> skribis:

> Tell git where to look for diff hunk headers: top-level definitions for
> Scheme files, and (sub)section headers for texi files.
>
> * .gitattributes, etc/git/gitconfig: New files.
> * doc/contributing.texi ("Submitting Patches"): Add subsection
> "Configuring Git".  Document etc/git/gitconfig.

I have one last question:

> +format-patch} sent to the @email{guix-patches@@gnu.org} mailing list
> +(@pxref{submitting patches,, Submitting patches to a project, git, Git
> +User Manual}).  Contributors are encouraged to take a moment to set some

AFAICS, there=E2=80=99s no Info-format Git manual, is there?  In that case,=
 the
pxref above is incorrect, but we can use @uref instead and/or suggest
=E2=80=98man git=E2=80=99 or similar.

The rest LGTM, thank you, and thanks Kyle!

Ludo=E2=80=99.




Message sent to guix-patches@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: [bug#50363] [PATCH v4] Improve default diff hunk header detection.
Resent-From: Sarah Morgensen <iskarian@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: guix-patches@HIDDEN
Resent-Date: Wed, 22 Sep 2021 16:23:02 +0000
Resent-Message-ID: <handler.50363.B50363.163232777129517 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 50363
X-GNU-PR-Package: guix-patches
X-GNU-PR-Keywords: patch
To: Ludovic =?UTF-8?Q?Court=C3=A8s?= <ludo@HIDDEN>
Cc: 50363 <at> debbugs.gnu.org, kyle@HIDDEN, maximedevos@HIDDEN
Received: via spool by 50363-submit <at> debbugs.gnu.org id=B50363.163232777129517
          (code B ref 50363); Wed, 22 Sep 2021 16:23:02 +0000
Received: (at 50363) by debbugs.gnu.org; 22 Sep 2021 16:22:51 +0000
Received: from localhost ([127.0.0.1]:51522 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1mT51H-0007g0-GY
	for submit <at> debbugs.gnu.org; Wed, 22 Sep 2021 12:22:51 -0400
Received: from out1.migadu.com ([91.121.223.63]:27719)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <iskarian@HIDDEN>) id 1mT51E-0007fm-Fp
 for 50363 <at> debbugs.gnu.org; Wed, 22 Sep 2021 12:22:49 -0400
X-Report-Abuse: Please report any abuse attempt to abuse@HIDDEN and
 include these headers.
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mgsn.dev; s=key1;
 t=1632327766;
 h=from:from:reply-to:subject:subject:date:date:message-id:message-id:
 to:to:cc:cc:mime-version:mime-version:content-type:content-type:
 content-transfer-encoding:content-transfer-encoding:
 in-reply-to:in-reply-to:references:references;
 bh=KgEhmKJBk5cBq29Wc9QWylRIZH3ln8juSFQBehbotyg=;
 b=IUPwpTjfaxFtlWfjKWJt8mtRHqOQvDU6O87PbYqtXQoKoml2cvRvmXGF5HWURf7xmJuM4/
 i9x/O8R1z6Zx28i86Wa84qkIq3mQW1AjXKFf4tsJ21D/wyGFFyqqztwsz7rrbeDHODFkzq
 vy1rduNg6nfVRuPQjVKfNj5VWbK8HYs=
From: Sarah Morgensen <iskarian@HIDDEN>
References: <e6e08312afa17ee812f8b538118bec6da86d3357.1630708121.git.iskarian@HIDDEN>
 <bbac973c0d0388fabe126bd44b60b0683ffe9f03.1632180690.git.iskarian@HIDDEN>
 <87o88khirl.fsf@HIDDEN>
Date: Wed, 22 Sep 2021 09:22:43 -0700
In-Reply-To: <87o88khirl.fsf@HIDDEN> ("Ludovic =?UTF-8?Q?Court=C3=A8s?="'s message of "Wed, 22
 Sep 2021 14:55:26 +0200 (3 hours, 20 minutes, 47 seconds ago)")
Message-ID: <86zgs4wpf0.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
X-Migadu-Flow: FLOW_OUT
X-Migadu-Auth-User: iskarian@HIDDEN
X-Spam-Score: -0.7 (/)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.7 (-)

Hi Ludo,

> I have one last question:
>
>> +format-patch} sent to the @email{guix-patches@@gnu.org} mailing list
>> +(@pxref{submitting patches,, Submitting patches to a project, git, Git
>> +User Manual}).  Contributors are encouraged to take a moment to set some
>
> AFAICS, there=E2=80=99s no Info-format Git manual, is there?  In that cas=
e, the
> pxref above is incorrect, but we can use @uref instead and/or suggest
> =E2=80=98man git=E2=80=99 or similar.

We don't currently build it, but there is.  In the git repo, in
Documentation/Makefile:

--8<---------------cut here---------------start------------->8---
info: git.info gitman.info
[...]
git.info: user-manual.texi
	$(QUIET_MAKEINFO)$(MAKEINFO) --no-split -o $@ user-manual.texi
--8<---------------cut here---------------end--------------->8---

It's available online at

  https://git-scm.com/docs/user-manual

and

  https://mirrors.edge.kernel.org/pub/software/scm/git/docs/user-manual.html


My other patch, #50683, adds this reference to htmlxref.cnf.

>
> The rest LGTM, thank you, and thanks Kyle!
>
> Ludo=E2=80=99.

--
Sarah




Message sent:


MIME-Version: 1.0
X-Mailer: MIME-tools 5.505 (Entity 5.505)
X-Loop: help-debbugs@HIDDEN
From: help-debbugs@HIDDEN (GNU bug Tracking System)
To: Ludovic =?UTF-8?Q?Court=C3=A8s?= <ludo@HIDDEN>
Subject: bug#50363: closed ([PATCH] Improve default diff hunk header
 detection.)
CC: tracker <at> debbugs.gnu.org
Message-ID: <handler.50363.D50363.16333503866534.ackdone <at> debbugs.gnu.org>
References: <874k9xq8m2.fsf_-_@HIDDEN>
 <e6e08312afa17ee812f8b538118bec6da86d3357.1630708121.git.iskarian@HIDDEN>
X-Gnu-PR-Message: closed 50363
X-Gnu-PR-Package: guix-patches
X-Gnu-PR-Keywords: patch
Date: Mon, 04 Oct 2021 12:27:02 +0000
Content-Type: multipart/mixed; boundary="----------=_1633350422-6579-0"

This is a multi-part message in MIME format...

------------=_1633350422-6579-0
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
Content-Type: text/plain; charset=utf-8

Your message dated Mon, 04 Oct 2021 14:26:13 +0200
with message-id <874k9xq8m2.fsf_-_@HIDDEN>
and subject line Re: bug#50363: [PATCH] Improve default diff hunk header de=
tection.
has caused the debbugs.gnu.org bug report #50363,
regarding [PATCH] Improve default diff hunk header detection.
to be marked as done.

(If you believe you have received this mail in error, please contact
help-debbugs@HIDDEN)


--=20
50363: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D50363
GNU Bug Tracking System
Contact help-debbugs@HIDDEN with problems

------------=_1633350422-6579-0
Content-Type: message/rfc822
Content-Disposition: inline
Content-Transfer-Encoding: 7bit

Received: (at submit) by debbugs.gnu.org; 3 Sep 2021 22:39:24 +0000
Received: from localhost ([127.0.0.1]:46029 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1mMHqF-000329-KC
	for submit <at> debbugs.gnu.org; Fri, 03 Sep 2021 18:39:23 -0400
Received: from lists.gnu.org ([209.51.188.17]:59120)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <iskarian@HIDDEN>) id 1mMHq7-00031u-67
 for submit <at> debbugs.gnu.org; Fri, 03 Sep 2021 18:39:21 -0400
Received: from eggs.gnu.org ([2001:470:142:3::10]:41356)
 by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <iskarian@HIDDEN>) id 1mMHq6-00024P-Vm
 for guix-patches@HIDDEN; Fri, 03 Sep 2021 18:39:14 -0400
Received: from out2.migadu.com ([2001:41d0:2:aacc::]:10642)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <iskarian@HIDDEN>) id 1mMHq4-00085a-FU
 for guix-patches@HIDDEN; Fri, 03 Sep 2021 18:39:14 -0400
X-Report-Abuse: Please report any abuse attempt to abuse@HIDDEN and
 include these headers.
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mgsn.dev; s=key1;
 t=1630708748;
 h=from:from:reply-to:subject:subject:date:date:message-id:message-id:
 to:to:cc:mime-version:mime-version:
 content-transfer-encoding:content-transfer-encoding;
 bh=IBSs7glMitEYgu7Vy9BZBhSgGazJt+PyVtxbTTs6hSk=;
 b=Yn9ipum4YxeeeZOiUJ/kqcjh/1+esUbJpJ9e3E0kdJdHMk0x76uzCuRwtTCfhjTig5Pjk0
 dKh1qWVCUYyNXZgMOYNUt/+ElNpDZE99R16ul18PrIX08qaJ6dAlke1O7009K0C+tVjebw
 de/wtr15yUMw4jw1pu0Dl+pMKajzVeU=
From: Sarah Morgensen <iskarian@HIDDEN>
To: guix-patches@HIDDEN
Subject: [PATCH v2] Improve default diff hunk header detection.
Date: Fri,  3 Sep 2021 15:39:05 -0700
Message-Id: <e6e08312afa17ee812f8b538118bec6da86d3357.1630708121.git.iskarian@HIDDEN>
MIME-Version: 1.0
Content-Transfer-Encoding: 8bit
X-Migadu-Flow: FLOW_OUT
X-Migadu-Auth-User: iskarian@HIDDEN
Received-SPF: pass client-ip=2001:41d0:2:aacc::;
 envelope-from=iskarian@HIDDEN; helo=out2.migadu.com
X-Spam_score_int: -27
X-Spam_score: -2.8
X-Spam_bar: --
X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1,
 DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1,
 RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_NONE=0.001,
 SPF_PASS=-0.001 autolearn=ham autolearn_force=no
X-Spam_action: no action
X-Spam-Score: 0.9 (/)
X-Debbugs-Envelope-To: submit
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -2.4 (--)

Tell git to look for top-level definitions for diff hunk headers in
Scheme files.

.gitattributes: New file.
.gitconfig: New file.
---
Hello Guix,

This patch improves the diff hunk headers for diffs on scheme files in this
repository.  These settings are always settable (and overridable) on a
per-user basis, but I think having them as defaults is nice.

This may help with patches applying in general, but the main goal is to make
etc/committer.scm a little less brittle.

The default "scheme" function regex (enabled with .gitattributes) recognizes
both toplevel and non-toplevel defines.  I've modified the regex in .gitconfig
to only recognize the toplevel defines.  I think this makes more sense for our
purposes.

Unfortunately, checked-in git config settings cannot be automatically used
(for security reasons), and must be enabled with a once-per-clone

  git config --local include.path ../.gitconfig

which isn't ideal.  I suppose we could make a 'make' target for setup like
this if we wanted to make it easy.

WDYT?

--
Sarah

 .gitattributes | 2 ++
 .gitconfig     | 2 ++
 2 files changed, 4 insertions(+)
 create mode 100644 .gitattributes
 create mode 100644 .gitconfig

diff --git a/.gitattributes b/.gitattributes
new file mode 100644
index 0000000000..5c1b15e9e0
--- /dev/null
+++ b/.gitattributes
@@ -0,0 +1,2 @@
+*.scm       diff=scheme
+*.scm.in    diff=scheme
diff --git a/.gitconfig b/.gitconfig
new file mode 100644
index 0000000000..344d829824
--- /dev/null
+++ b/.gitconfig
@@ -0,0 +1,2 @@
+[diff "scheme"]
+	xfuncname = "^(\\(define.*)$"

base-commit: 522a3bf99cbc21a9093f63280b9508cd69b94ff0
-- 
2.31.1




------------=_1633350422-6579-0
Content-Type: message/rfc822
Content-Disposition: inline
Content-Transfer-Encoding: 7bit

Received: (at 50363-done) by debbugs.gnu.org; 4 Oct 2021 12:26:26 +0000
Received: from localhost ([127.0.0.1]:35854 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1mXN33-0001hK-O2
	for submit <at> debbugs.gnu.org; Mon, 04 Oct 2021 08:26:25 -0400
Received: from eggs.gnu.org ([209.51.188.92]:43704)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <ludo@HIDDEN>) id 1mXN31-0001h7-CS
 for 50363-done <at> debbugs.gnu.org; Mon, 04 Oct 2021 08:26:24 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:51016)
 by eggs.gnu.org with esmtp (Exim 4.90_1)
 (envelope-from <ludo@HIDDEN>)
 id 1mXN2t-0004Cm-Kq; Mon, 04 Oct 2021 08:26:15 -0400
Received: from [2001:660:6102:320:e120:2c8f:8909:cdfe] (port=60540 helo=ribbon)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <ludo@HIDDEN>)
 id 1mXN2t-0000xr-Aw; Mon, 04 Oct 2021 08:26:15 -0400
From: =?utf-8?Q?Ludovic_Court=C3=A8s?= <ludo@HIDDEN>
To: Sarah Morgensen <iskarian@HIDDEN>
Subject: Re: bug#50363: [PATCH] Improve default diff hunk header detection.
References: <e6e08312afa17ee812f8b538118bec6da86d3357.1630708121.git.iskarian@HIDDEN>
 <bbac973c0d0388fabe126bd44b60b0683ffe9f03.1632180690.git.iskarian@HIDDEN>
 <87o88khirl.fsf@HIDDEN> <86zgs4wpf0.fsf@HIDDEN>
Date: Mon, 04 Oct 2021 14:26:13 +0200
In-Reply-To: <86zgs4wpf0.fsf@HIDDEN> (Sarah Morgensen's message of "Wed, 22
 Sep 2021 09:22:43 -0700")
Message-ID: <874k9xq8m2.fsf_-_@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 50363-done
Cc: 50363-done <at> debbugs.gnu.org, kyle@HIDDEN, maximedevos@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

Hi Sarah,

Sarah Morgensen <iskarian@HIDDEN> skribis:

>> I have one last question:
>>
>>> +format-patch} sent to the @email{guix-patches@@gnu.org} mailing list
>>> +(@pxref{submitting patches,, Submitting patches to a project, git, Git
>>> +User Manual}).  Contributors are encouraged to take a moment to set so=
me
>>
>> AFAICS, there=E2=80=99s no Info-format Git manual, is there?  In that ca=
se, the
>> pxref above is incorrect, but we can use @uref instead and/or suggest
>> =E2=80=98man git=E2=80=99 or similar.
>
> We don't currently build it, but there is.  In the git repo, in
> Documentation/Makefile:
>
> info: git.info gitman.info
> [...]
> git.info: user-manual.texi
> 	$(QUIET_MAKEINFO)$(MAKEINFO) --no-split -o $@ user-manual.texi
>
> It's available online at
>
>   https://git-scm.com/docs/user-manual
>
> and
>
>   https://mirrors.edge.kernel.org/pub/software/scm/git/docs/user-manual.h=
tml
>
> My other patch, #50683, adds this reference to htmlxref.cnf.

Oh, nice; thanks for explaining.

Finally applied!

Ludo=E2=80=99.


------------=_1633350422-6579-0--


Message sent:


MIME-Version: 1.0
X-Mailer: MIME-tools 5.505 (Entity 5.505)
X-Loop: help-debbugs@HIDDEN
From: help-debbugs@HIDDEN (GNU bug Tracking System)
To: Sarah Morgensen <iskarian@HIDDEN>
Subject: bug#50363: closed (Re: bug#50363: [PATCH] Improve default diff
 hunk header detection.)
Message-ID: <handler.50363.D50363.16333503866534.notifdone <at> debbugs.gnu.org>
References: <874k9xq8m2.fsf_-_@HIDDEN>
 <e6e08312afa17ee812f8b538118bec6da86d3357.1630708121.git.iskarian@HIDDEN>
X-Gnu-PR-Message: they-closed 50363
X-Gnu-PR-Package: guix-patches
X-Gnu-PR-Keywords: patch
Reply-To: 50363 <at> debbugs.gnu.org
Date: Mon, 04 Oct 2021 12:27:02 +0000
Content-Type: multipart/mixed; boundary="----------=_1633350422-6579-1"

This is a multi-part message in MIME format...

------------=_1633350422-6579-1
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
Content-Type: text/plain; charset="utf-8"

Your bug report

#50363: [PATCH] Improve default diff hunk header detection.

which was filed against the guix-patches package, has been closed.

The explanation is attached below, along with your original report.
If you require more details, please reply to 50363 <at> debbugs.gnu.org.

--=20
50363: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D50363
GNU Bug Tracking System
Contact help-debbugs@HIDDEN with problems

------------=_1633350422-6579-1
Content-Type: message/rfc822
Content-Disposition: inline
Content-Transfer-Encoding: 7bit

Received: (at 50363-done) by debbugs.gnu.org; 4 Oct 2021 12:26:26 +0000
Received: from localhost ([127.0.0.1]:35854 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1mXN33-0001hK-O2
	for submit <at> debbugs.gnu.org; Mon, 04 Oct 2021 08:26:25 -0400
Received: from eggs.gnu.org ([209.51.188.92]:43704)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <ludo@HIDDEN>) id 1mXN31-0001h7-CS
 for 50363-done <at> debbugs.gnu.org; Mon, 04 Oct 2021 08:26:24 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:51016)
 by eggs.gnu.org with esmtp (Exim 4.90_1)
 (envelope-from <ludo@HIDDEN>)
 id 1mXN2t-0004Cm-Kq; Mon, 04 Oct 2021 08:26:15 -0400
Received: from [2001:660:6102:320:e120:2c8f:8909:cdfe] (port=60540 helo=ribbon)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <ludo@HIDDEN>)
 id 1mXN2t-0000xr-Aw; Mon, 04 Oct 2021 08:26:15 -0400
From: =?utf-8?Q?Ludovic_Court=C3=A8s?= <ludo@HIDDEN>
To: Sarah Morgensen <iskarian@HIDDEN>
Subject: Re: bug#50363: [PATCH] Improve default diff hunk header detection.
References: <e6e08312afa17ee812f8b538118bec6da86d3357.1630708121.git.iskarian@HIDDEN>
 <bbac973c0d0388fabe126bd44b60b0683ffe9f03.1632180690.git.iskarian@HIDDEN>
 <87o88khirl.fsf@HIDDEN> <86zgs4wpf0.fsf@HIDDEN>
Date: Mon, 04 Oct 2021 14:26:13 +0200
In-Reply-To: <86zgs4wpf0.fsf@HIDDEN> (Sarah Morgensen's message of "Wed, 22
 Sep 2021 09:22:43 -0700")
Message-ID: <874k9xq8m2.fsf_-_@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 50363-done
Cc: 50363-done <at> debbugs.gnu.org, kyle@HIDDEN, maximedevos@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

Hi Sarah,

Sarah Morgensen <iskarian@HIDDEN> skribis:

>> I have one last question:
>>
>>> +format-patch} sent to the @email{guix-patches@@gnu.org} mailing list
>>> +(@pxref{submitting patches,, Submitting patches to a project, git, Git
>>> +User Manual}).  Contributors are encouraged to take a moment to set so=
me
>>
>> AFAICS, there=E2=80=99s no Info-format Git manual, is there?  In that ca=
se, the
>> pxref above is incorrect, but we can use @uref instead and/or suggest
>> =E2=80=98man git=E2=80=99 or similar.
>
> We don't currently build it, but there is.  In the git repo, in
> Documentation/Makefile:
>
> info: git.info gitman.info
> [...]
> git.info: user-manual.texi
> 	$(QUIET_MAKEINFO)$(MAKEINFO) --no-split -o $@ user-manual.texi
>
> It's available online at
>
>   https://git-scm.com/docs/user-manual
>
> and
>
>   https://mirrors.edge.kernel.org/pub/software/scm/git/docs/user-manual.h=
tml
>
> My other patch, #50683, adds this reference to htmlxref.cnf.

Oh, nice; thanks for explaining.

Finally applied!

Ludo=E2=80=99.


------------=_1633350422-6579-1
Content-Type: message/rfc822
Content-Disposition: inline
Content-Transfer-Encoding: 7bit

Received: (at submit) by debbugs.gnu.org; 3 Sep 2021 22:39:24 +0000
Received: from localhost ([127.0.0.1]:46029 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1mMHqF-000329-KC
	for submit <at> debbugs.gnu.org; Fri, 03 Sep 2021 18:39:23 -0400
Received: from lists.gnu.org ([209.51.188.17]:59120)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <iskarian@HIDDEN>) id 1mMHq7-00031u-67
 for submit <at> debbugs.gnu.org; Fri, 03 Sep 2021 18:39:21 -0400
Received: from eggs.gnu.org ([2001:470:142:3::10]:41356)
 by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <iskarian@HIDDEN>) id 1mMHq6-00024P-Vm
 for guix-patches@HIDDEN; Fri, 03 Sep 2021 18:39:14 -0400
Received: from out2.migadu.com ([2001:41d0:2:aacc::]:10642)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <iskarian@HIDDEN>) id 1mMHq4-00085a-FU
 for guix-patches@HIDDEN; Fri, 03 Sep 2021 18:39:14 -0400
X-Report-Abuse: Please report any abuse attempt to abuse@HIDDEN and
 include these headers.
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mgsn.dev; s=key1;
 t=1630708748;
 h=from:from:reply-to:subject:subject:date:date:message-id:message-id:
 to:to:cc:mime-version:mime-version:
 content-transfer-encoding:content-transfer-encoding;
 bh=IBSs7glMitEYgu7Vy9BZBhSgGazJt+PyVtxbTTs6hSk=;
 b=Yn9ipum4YxeeeZOiUJ/kqcjh/1+esUbJpJ9e3E0kdJdHMk0x76uzCuRwtTCfhjTig5Pjk0
 dKh1qWVCUYyNXZgMOYNUt/+ElNpDZE99R16ul18PrIX08qaJ6dAlke1O7009K0C+tVjebw
 de/wtr15yUMw4jw1pu0Dl+pMKajzVeU=
From: Sarah Morgensen <iskarian@HIDDEN>
To: guix-patches@HIDDEN
Subject: [PATCH v2] Improve default diff hunk header detection.
Date: Fri,  3 Sep 2021 15:39:05 -0700
Message-Id: <e6e08312afa17ee812f8b538118bec6da86d3357.1630708121.git.iskarian@HIDDEN>
MIME-Version: 1.0
Content-Transfer-Encoding: 8bit
X-Migadu-Flow: FLOW_OUT
X-Migadu-Auth-User: iskarian@HIDDEN
Received-SPF: pass client-ip=2001:41d0:2:aacc::;
 envelope-from=iskarian@HIDDEN; helo=out2.migadu.com
X-Spam_score_int: -27
X-Spam_score: -2.8
X-Spam_bar: --
X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1,
 DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1,
 RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_NONE=0.001,
 SPF_PASS=-0.001 autolearn=ham autolearn_force=no
X-Spam_action: no action
X-Spam-Score: 0.9 (/)
X-Debbugs-Envelope-To: submit
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -2.4 (--)

Tell git to look for top-level definitions for diff hunk headers in
Scheme files.

.gitattributes: New file.
.gitconfig: New file.
---
Hello Guix,

This patch improves the diff hunk headers for diffs on scheme files in this
repository.  These settings are always settable (and overridable) on a
per-user basis, but I think having them as defaults is nice.

This may help with patches applying in general, but the main goal is to make
etc/committer.scm a little less brittle.

The default "scheme" function regex (enabled with .gitattributes) recognizes
both toplevel and non-toplevel defines.  I've modified the regex in .gitconfig
to only recognize the toplevel defines.  I think this makes more sense for our
purposes.

Unfortunately, checked-in git config settings cannot be automatically used
(for security reasons), and must be enabled with a once-per-clone

  git config --local include.path ../.gitconfig

which isn't ideal.  I suppose we could make a 'make' target for setup like
this if we wanted to make it easy.

WDYT?

--
Sarah

 .gitattributes | 2 ++
 .gitconfig     | 2 ++
 2 files changed, 4 insertions(+)
 create mode 100644 .gitattributes
 create mode 100644 .gitconfig

diff --git a/.gitattributes b/.gitattributes
new file mode 100644
index 0000000000..5c1b15e9e0
--- /dev/null
+++ b/.gitattributes
@@ -0,0 +1,2 @@
+*.scm       diff=scheme
+*.scm.in    diff=scheme
diff --git a/.gitconfig b/.gitconfig
new file mode 100644
index 0000000000..344d829824
--- /dev/null
+++ b/.gitconfig
@@ -0,0 +1,2 @@
+[diff "scheme"]
+	xfuncname = "^(\\(define.*)$"

base-commit: 522a3bf99cbc21a9093f63280b9508cd69b94ff0
-- 
2.31.1




------------=_1633350422-6579-1--


Message sent to guix-patches@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: [bug#50363] [PATCH] Improve default diff hunk header detection.
Resent-From: Marius Bakke <marius@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: guix-patches@HIDDEN
Resent-Date: Wed, 13 Oct 2021 22:32:02 +0000
Resent-Message-ID: <handler.50363.D50363.163416427017584 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 50363
X-GNU-PR-Package: guix-patches
X-GNU-PR-Keywords: patch
To: Ludovic =?UTF-8?Q?Court=C3=A8s?= <ludo@HIDDEN>, Sarah Morgensen <iskarian@HIDDEN>
Cc: 50363-done <at> debbugs.gnu.org
Received: via spool by 50363-done <at> debbugs.gnu.org id=D50363.163416427017584
          (code D ref 50363); Wed, 13 Oct 2021 22:32:02 +0000
Received: (at 50363-done) by debbugs.gnu.org; 13 Oct 2021 22:31:10 +0000
Received: from localhost ([127.0.0.1]:33854 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1mammD-0004YY-AG
	for submit <at> debbugs.gnu.org; Wed, 13 Oct 2021 18:31:10 -0400
Received: from eggs.gnu.org ([209.51.188.92]:52700)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <marius@HIDDEN>) id 1mamm7-0004Q1-Vn
 for 50363-done <at> debbugs.gnu.org; Wed, 13 Oct 2021 18:31:07 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:51376)
 by eggs.gnu.org with esmtp (Exim 4.90_1)
 (envelope-from <marius@HIDDEN>)
 id 1mamm2-0002eR-GH; Wed, 13 Oct 2021 18:30:58 -0400
Received: from host-37-191-236-102.lynet.no ([37.191.236.102]:35170
 helo=localhost)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <marius@HIDDEN>)
 id 1mamlx-0002Kj-UB; Wed, 13 Oct 2021 18:30:54 -0400
From: Marius Bakke <marius@HIDDEN>
In-Reply-To: <874k9xq8m2.fsf_-_@HIDDEN>
References: <e6e08312afa17ee812f8b538118bec6da86d3357.1630708121.git.iskarian@HIDDEN>
 <bbac973c0d0388fabe126bd44b60b0683ffe9f03.1632180690.git.iskarian@HIDDEN>
 <87o88khirl.fsf@HIDDEN> <86zgs4wpf0.fsf@HIDDEN>
 <874k9xq8m2.fsf_-_@HIDDEN>
Date: Thu, 14 Oct 2021 00:30:50 +0200
Message-ID: <87wnmgk15x.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: multipart/signed; boundary="=-=-=";
 micalg=pgp-sha512; protocol="application/pgp-signature"
X-Spam-Score: -2.3 (--)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

--=-=-=
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable

Ludovic Court=C3=A8s <ludo@HIDDEN> skriver:

> Finally applied!

It looks like this commit contained the documentation changes only.
Fixed in f8b10932c86cf4c1657a67e8c484d76f757b64bd.  :-)

--=-=-=
Content-Type: application/pgp-signature; name="signature.asc"

-----BEGIN PGP SIGNATURE-----

iIUEARYKAC0WIQRNTknu3zbaMQ2ddzTocYulkRQQdwUCYWdeGg8cbWFyaXVzQGdu
dS5vcmcACgkQ6HGLpZEUEHfC+wEA8Hj8TzKPHkL0k10cOORixM+/GFHc8s/kq1WX
gUrx/QEBAJOQ/ww/HGjfprby59DfOybUzpvZtr00XfkRdfXpS50J
=mWgE
-----END PGP SIGNATURE-----
--=-=-=--





Last modified: Wed, 13 Oct 2021 22:30:02 UTC

GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997 nCipher Corporation Ltd, 1994-97 Ian Jackson.