Subject: [bug#78219] [PATCH] gnu: Add python-vcstool

From: Matthew Elwin <[email-masked]>
Date: Tue, 6 May 2025 15:43:54 -0500

* gnu/packages/python-xyz.scm (python-vcstool): New Variable

Change-Id: I5e3485cd1f53a379121a09938d5e45cd641a0317
---
 gnu/packages/python-xyz.scm | 35 +++++++++++++++++++++++++++++++++++
 1 file changed, 35 insertions(+)

diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 32a01d70a2..24cb818faf 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -163,6 +163,7 @@
 ;;; Copyright © 2025 Dariqq <[email-masked]>
 ;;; Copyright © 2025 Nguyễn Gia Phong <[email-masked]>
 ;;; Copyright © 2025, Cayetano Santos <[email-masked]>
+;;; Copyright © 2025, Matthew Elwin <[email-masked]>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -5081,6 +5082,40 @@ (define-public python-case
 some helpful Python 2 compatibility convenience methods.")
     (license license:bsd-3)))
 
+(define-public python-vcstool
+  (package
+    (name "python-vcstool")
+    (version "0.3.0")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (pypi-uri "vcstool" version))
+       (sha256
+        (base32 "0b7f68q25x9nxqa3xcg32js3qgp4jg99anwy2c7nd1jkw5iskcq4"))))
+    (build-system pyproject-build-system)
+    (arguments
+     (list
+      #:phases
+      #~(modify-phases %standard-phases
+          (add-after 'wrap 'wrap-script
+            (lambda _
+              (wrap-program (string-append #$output "/bin/vcs")
+                `("PATH" prefix ,(list
+                                  (string-append #$git "/bin")
+                                  (string-append #$mercurial "/bin")
+                                  (string-append #$mercurial "/bin")
+                                  (string-append #$breezy "/bin")
+                                  (string-append #$subversion "/bin")
+                                  ))))))))
+    (propagated-inputs (list python-pyyaml python-setuptools))
+    (native-inputs (list python-setuptools python-wheel))
+    (home-page "https://github.com/dirk-thomas/vcstool")
+    (synopsis
+     "Command line tool to invoke version control commands on multiple repositories")
+    (description
+     "Enables manipulating multiple version control repositories with one command.")
+    (license license:asl2.0)))
+
 (define-public python-verboselogs
   (package
     (name "python-verboselogs")

base-commit: ec95c71c01144fcae1a3d079e0d0aec6087b9d2a
-- 
2.43.0