From: Patrick Steinhardt Date: Wed, 03 Jun 2026 06:58:58 GMT Subject: [PATCH v2 0/3] Documentation: recommend the use of b4 Message-ID: <20260603-pks-b4-v2-0-a8aea0aa2c23@pks.im> In-Reply-To: <20260602-pks-b4-v1-0-a7ae5a49e9cf@pks.im> Hi, this small patch series wires up b4 in Git and recommends the use thereof via "MyFirstContribution", as discussed in [1]. Changes in v2: - Reorder commits so that the b4 docs are added first. - Add a section that highlights how to configure b4, and that points out that the per-project defaults can be overridden via Git configuration. - Add a patch to MyFirstContribution that recommends shallow threading. I mostly intend this to be a discussion starter so that the `.b4-config` file matches our preferred threading style. - Fix a typo. - Link to v1: https://patch.msgid.link/20260602-pks-b4-v1-0-a7ae5a49e9cf@pks.im Thanks! Patrick [1]: --- Patrick Steinhardt (3): Documentation/MyFirstContribution: recommend shallow threading Documentation/MyFirstContribution: recommend the use of b4 b4: introduce configuration for the Git project .b4-config | 6 +++ .b4-cover-template | 11 ++++ Documentation/MyFirstContribution.adoc | 96 ++++++++++++++++++++++++++++++++-- Documentation/SubmittingPatches | 6 ++- 4 files changed, 112 insertions(+), 7 deletions(-) Range-diff versus v1: -: ---------- > 1: 359ce9ec24 Documentation/MyFirstContribution: recommend shallow threading 2: 55fffeb8f8 ! 2: ce9aa56846 Documentation/MyFirstContribution: recommend the use of b4 @@ Documentation/MyFirstContribution.adoc: index 88f126184c..38da593a60 100644 +version. `b4` automatically bumps the version to `v2`, generates the range-diff +against the previous iteration, and threads the new series as a reply to the +cover letter of the first version. ++ ++[[configure-b4]] ++=== Configure b4 ++ ++`b4` can be configured via linkgit:git-config[1]. In addition to that, projects ++can have their own set of defaults in `.b4-config` in the root tree, which also ++uses Git's config format. The user's configuration always takes precedence over ++the per-project defaults. ++ ++Refer to the https://b4.docs.kernel.org/en/latest/config.html[b4 config documentation] ++for more information on the available options. + [[now-what]] == My Patch Got Emailed - Now What? 1: 0fe6cf8511 ! 3: e2bf7b6e46 b4: introduce configuration for the Git project @@ Commit message b4: introduce configuration for the Git project We're about to extend our documentation to recommend b4 for sending - patch series ot the mailing list. Prepare for this by introducing a b4 + patch series to the mailing list. Prepare for this by introducing a b4 configuration so that the tool knows to honor our preferences. For now, this configuration does two things: @@ Commit message forward, like for example auto-configuration of folks to Cc on certain patches. But these two tweaks feel like a good place to start. + Note that these values only serve as defaults, and users may want to + tweak those defaults based on their own preference. Luckily, users can + do that without having to touch `.b4-config` at all, as b4 allows them + to override values via Git configuration: + + ``` + $ git config set b4.prep-cover-template /does/not/exist + $ b4 send --dry-run + ERROR: prep-cover-template says to use x, but it does not exist + ``` + + So this gives users an easy way to override our defaults without having + to touch ".b4-config", which would dirty the tree. + Signed-off-by: Patrick Steinhardt ## .b4-config (new) ## @@ ++# Note that these are default values that you can tweak via the typical ++# git-config(1) machinery. You thus shouldn't ever have to change this file. ++# See also https://b4.docs.kernel.org/en/latest/config.html. +[b4] +send-same-thread = shallow +prep-cover-template = ./.b4-cover-template --- base-commit: 9ac3f193c05c2237e2b14ebaa1149e9fc8a1abe0 change-id: 20260602-pks-b4-31cc20d7f84b