guix-commits
[Top][All Lists]
Advanced

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

03/03: gnu: i3-wm: Use absolute paths in session files.


From: guix-commits
Subject: 03/03: gnu: i3-wm: Use absolute paths in session files.
Date: Mon, 29 Apr 2019 22:38:21 -0400 (EDT)

samplet pushed a commit to branch master
in repository guix.

commit aa7cdc57dc28673dedfc6ec210974aaa0099a419
Author: Timothy Sample <address@hidden>
Date:   Mon Apr 29 22:36:27 2019 -0400

    gnu: i3-wm: Use absolute paths in session files.
    
    * gnu/packages/wm.scm (i3-wm)[arguments]: Add a phase to patch the
    session '.desktop' files to use the absolute paths of the 'i3' and
    'i3-with-shmlog' binaries.
---
 gnu/packages/wm.scm | 14 +++++++++++++-
 1 file changed, 13 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/wm.scm b/gnu/packages/wm.scm
index 6d650a8..ddc6905 100644
--- a/gnu/packages/wm.scm
+++ b/gnu/packages/wm.scm
@@ -182,7 +182,19 @@ commands would.")
        (list "--disable-builddir")
 
        ;; The test suite requires the unpackaged Xephyr X server.
-       #:tests? #f))
+       #:tests? #f
+       #:phases
+       (modify-phases %standard-phases
+         (add-after 'install 'patch-session-file
+           (lambda* (#:key outputs #:allow-other-keys)
+             (let* ((out (assoc-ref outputs "out"))
+                    (i3 (string-append out "/bin/i3"))
+                    (i3-with-shmlog (string-append out "/bin/i3-with-shmlog")))
+               (substitute* (string-append out "/share/xsessions/i3.desktop")
+                 (("Exec=i3") (string-append "Exec=" i3)))
+               (substitute* (string-append out 
"/share/xsessions/i3-with-shmlog.desktop")
+                 (("Exec=i3-with-shmlog") (string-append "Exec=" 
i3-with-shmlog)))
+               #t))))))
     (inputs
      `(("libxcb" ,libxcb)
        ("xcb-util" ,xcb-util)



reply via email to

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