unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
* [bug#44625] [PATCH] gnu: Add b4.
@ 2020-11-14  0:39 Kyle Meyer
  2020-11-14  2:14 ` zimoun
  2020-11-15 20:18 ` bug#44625: " Christopher Baines
  0 siblings, 2 replies; 6+ messages in thread
From: Kyle Meyer @ 2020-11-14  0:39 UTC (permalink / raw)
  To: 44625

* gnu/packages/version-control.scm (b4): New variable.
---

  b4 is focused on lore.kernel.org public-inbox archives, but it's useful for
  any public-inbox [1] instance, including yhetil.org/guix-patches :).  Here's
  an example with a recent multi-patch thread that involves multiple versions.

    $ # in the guix repo
    $ git config b4.attestation-policy off
    $ git config b4.midmask https://yhetil.org/guix-patches/%s
    $ b4 am 20201028165112.28575-1-zimon.toutoune@gmail.com

  The end result is a filtered mbox with the v2 patches.  Also, because the
  sender helpfully included the base commit, `b4 am' will use that information
  in the instructions that it outputs.

  If the above sounds useful to you but you'd prefer to work in Emacs, you
  might be interested in piem (<https://git.kyleam.com/piem/about/>), which
  includes a transient (i.e magit-popup's successor) interface to b4.

  [1] https://public-inbox.org/

 gnu/packages/version-control.scm | 41 ++++++++++++++++++++++++++++++++
 1 file changed, 41 insertions(+)

diff --git a/gnu/packages/version-control.scm b/gnu/packages/version-control.scm
index 16c70bd1a7..de7c961cea 100644
--- a/gnu/packages/version-control.scm
+++ b/gnu/packages/version-control.scm
@@ -2301,6 +2301,47 @@ (define-public grokmirror
 based on a manifest file published by servers.")
     (license license:gpl3+)))
 
+(define-public b4
+  (package
+    (name "b4")
+    (version "0.5.2")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://git.kernel.org/pub/scm/utils/b4/b4.git")
+             (commit (string-append "v" version))))
+       (file-name (string-append name "-" version "-checkout"))
+       (sha256
+        (base32 "1w11fiyspyncz2m7njrjfylgzch4azi7560ngd8i733wvjjhg3mj"))))
+    (build-system python-build-system)
+    (arguments
+     `(#:tests? #f                      ; No tests.
+       #:phases
+       (modify-phases %standard-phases
+         (add-after 'install 'install-manpages
+           (lambda* (#:key outputs #:allow-other-keys)
+             (let ((man (string-append (assoc-ref outputs "out")
+                                       "/man/man5/")))
+               (mkdir-p man)
+               (for-each (lambda (file) (install-file file man))
+                         (find-files "man" "\\.[1-8]$")))
+             #t)))))
+    (inputs
+     `(("python-requests" ,python-requests)))
+    (home-page "https://git.kernel.org/pub/scm/utils/b4/b4.git")
+    (synopsis "Tool for working with patches in public-inbox archives")
+    (description "The @code{b4} command is designed to make it easier to
+participate in patch-based workflows for projects that have public-inbox
+archives.  Features include
+@itemize
+@item downloading a thread's mbox given a message ID
+@item processing an mbox so that is ready to be fed to @code{git-am}
+@item creating templated replies for processed patches and pull requests
+@item submitting cryptographic attestation for patches.
+@end itemize")
+    (license license:gpl2+)))
+
 (define-public git-annex-remote-rclone
   (package
     (name "git-annex-remote-rclone")

base-commit: 4e9b2e8ba26dd601df67f112852237d5df2f3341
-- 
2.29.2.454.gaff20da3a2





^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2020-11-15 20:54 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-11-14  0:39 [bug#44625] [PATCH] gnu: Add b4 Kyle Meyer
2020-11-14  2:14 ` zimoun
2020-11-14  5:22   ` Kyle Meyer
2020-11-14 13:36     ` zimoun
2020-11-15 20:18 ` bug#44625: " Christopher Baines
2020-11-15 20:53   ` [bug#44625] " Kyle Meyer

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).