guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

branch master updated: gnu: git-open: Remove unnecessary propagated inpu


From: guix-commits
Subject: branch master updated: gnu: git-open: Remove unnecessary propagated input.
Date: Fri, 04 Dec 2020 23:39:11 -0500

This is an automated email from the git hooks/post-receive script.

lfam pushed a commit to branch master
in repository guix.

The following commit(s) were added to refs/heads/master by this push:
     new 4cf3734  gnu: git-open: Remove unnecessary propagated input.
4cf3734 is described below

commit 4cf3734c56d669ee2d78082e5d7c4d0a58e0f800
Author: EuAndreh <eu@euandre.org>
AuthorDate: Fri Dec 4 17:53:32 2020 -0300

    gnu: git-open: Remove unnecessary propagated input.
    
    * gnu/packages/version-control.scm (git-open)[arguments]: Wrap the git-open
    executable with the path to xdg-utils.
    [propagated-inputs]: Replace with ...
    [inputs]: New field.
    [build-system]: Use copy-build-system.
    
    Signed-off-by: Leo Famulari <leo@famulari.name>
---
 gnu/packages/version-control.scm | 25 +++++++++++++------------
 1 file changed, 13 insertions(+), 12 deletions(-)

diff --git a/gnu/packages/version-control.scm b/gnu/packages/version-control.scm
index a8e6d2c..eec57b3 100644
--- a/gnu/packages/version-control.scm
+++ b/gnu/packages/version-control.scm
@@ -55,6 +55,7 @@
   #:use-module (guix git-download)
   #:use-module (guix hg-download)
   #:use-module (guix build-system cmake)
+  #:use-module (guix build-system copy)
   #:use-module (guix build-system gnu)
   #:use-module (guix build-system go)
   #:use-module (guix build-system perl)
@@ -2733,20 +2734,20 @@ file contents on a remote server.")
        (file-name (git-file-name name version))
        (sha256
         (base32 "11n46bngvca5wbdbfcxzjhjbfdbad7sgf7h9gf956cb1q8swsdm0"))))
-    (build-system trivial-build-system)
-    (propagated-inputs
+    (build-system copy-build-system)
+    (inputs
      `(("xdg-utils" ,xdg-utils)))
     (arguments
-     `(#:modules ((guix build utils))
-       #:builder
-       (begin
-         (use-modules (guix build utils))
-         (let ((source (assoc-ref %build-inputs "source"))
-               (out    (assoc-ref %outputs "out")))
-           (mkdir-p (string-append out "/bin"))
-           (copy-file (string-append source "/git-open")
-                      (string-append out "/bin/git-open"))
-           #t))))
+     `(#:phases
+       (modify-phases %standard-phases
+         (add-after 'install 'wrap-program
+           (lambda* (#:key outputs inputs #:allow-other-keys)
+             (let ((out (assoc-ref outputs "out"))
+                   (xdg-utils (assoc-ref inputs "xdg-utils")))
+               (wrap-program (string-append out "/bin/git-open")
+                 `("PATH" ":" prefix (,(string-append xdg-utils "/bin"))))))))
+       #:install-plan
+       '(("git-open" "bin/git-open"))))
     (home-page "https://github.com/paulirish/git-open";)
     (synopsis "Open a Git repository's homepage from the command-line")
     (description



reply via email to

[Prev in Thread] Current Thread [Next in Thread]