diff mbox series

[bug#71937,2/2] gnu: distrobox: Patch distrobox-generate-entry.

Message ID 83b646b35ad823da12214add2855c89b4c89ab80.1720087651.git.jean@foundation.xyz
State New
Headers show
Series gnu: distrobox: Update to 1.7.2.1. | expand

Commit Message

Jean-Pierre De Jesus DIAZ July 4, 2024, 10:11 a.m. UTC
Avoids keeping store references in generated desktop files.

* gnu/packages/containers.scm (distrobox)<arguments>: add
'patch-distrobox-generate-entry phase.

Change-Id: Ib1bffaefa1805accb5227c289c9fc985853bc675
---
 gnu/packages/containers.scm | 8 ++++++++
 1 file changed, 8 insertions(+)
diff mbox series

Patch

diff --git a/gnu/packages/containers.scm b/gnu/packages/containers.scm
index 9b17f6601e..1bfa18b4b9 100644
--- a/gnu/packages/containers.scm
+++ b/gnu/packages/containers.scm
@@ -174,6 +174,14 @@  (define-public distrobox
     (arguments
      (list #:phases
            #~(modify-phases %standard-phases
+               ;; This script creates desktop files but when the store path for
+               ;; distrobox changes it leaves the stale path on the desktop
+               ;; file, so remove the path to use the profile's current
+               ;; distrobox.
+               (add-after 'unpack 'patch-distrobox-generate-entry
+                 (lambda _
+                   (substitute* "distrobox-generate-entry"
+                     (("\\$\\{distrobox_path\\}/distrobox") "distrobox"))))
                ;; Use WRAP-SCRIPT to wrap all of the scripts of distrobox,
                ;; excluding the host side ones.
                (add-after 'install 'wrap-scripts