diff options
| author | Efraim Flashner <efraim@flashner.co.il> | 2026-05-17 14:59:13 +0300 |
|---|---|---|
| committer | Efraim Flashner <efraim@flashner.co.il> | 2026-05-17 16:38:54 +0300 |
| commit | 918e2ae85221596469a079af7c15c9b77691603e (patch) | |
| tree | 7da25d12a6021b8901063f1911c2e33f40349f65 /gnu/packages | |
| parent | e7c07af6561f03307f85012bf74e2e9ee5069c3b (diff) | |
gnu: eza: Simplify installing extras.
* gnu/packages/rust-apps.scm (eza)[arguments]: Rewrite the 'build-manual
and 'install-extras phases to use the copy-build-system's install phase.
Change-Id: I7cebd3a5c529dd54cafbbfba6a59a702c3e362fc
Diffstat (limited to 'gnu/packages')
| -rw-r--r-- | gnu/packages/rust-apps.scm | 54 |
1 files changed, 27 insertions, 27 deletions
diff --git a/gnu/packages/rust-apps.scm b/gnu/packages/rust-apps.scm index c2fbe4845ca..cc197d74be7 100644 --- a/gnu/packages/rust-apps.scm +++ b/gnu/packages/rust-apps.scm | |||
| @@ -1377,10 +1377,15 @@ console.") | |||
| 1377 | (arguments | 1377 | (arguments |
| 1378 | (list | 1378 | (list |
| 1379 | #:install-source? #f | 1379 | #:install-source? #f |
| 1380 | #:imported-modules (append %copy-build-system-modules | ||
| 1381 | %cargo-build-system-modules) | ||
| 1382 | #:modules '((guix build cargo-build-system) | ||
| 1383 | ((guix build copy-build-system) #:prefix copy:) | ||
| 1384 | (guix build utils)) | ||
| 1380 | #:phases | 1385 | #:phases |
| 1381 | #~(modify-phases %standard-phases | 1386 | #~(modify-phases %standard-phases |
| 1382 | (add-after 'build 'build-manual | 1387 | (add-after 'install 'install-manual |
| 1383 | (lambda* (#:key inputs #:allow-other-keys) | 1388 | (lambda* (#:key inputs #:allow-other-keys #:rest args) |
| 1384 | (when (assoc-ref inputs "pandoc") | 1389 | (when (assoc-ref inputs "pandoc") |
| 1385 | (map (lambda (page) | 1390 | (map (lambda (page) |
| 1386 | (with-output-to-file page | 1391 | (with-output-to-file page |
| @@ -1391,31 +1396,26 @@ console.") | |||
| 1391 | (string-append "man/" page ".md"))))) | 1396 | (string-append "man/" page ".md"))))) |
| 1392 | (list "eza.1" | 1397 | (list "eza.1" |
| 1393 | "eza_colors.5" | 1398 | "eza_colors.5" |
| 1394 | "eza_colors-explanation.5"))))) | 1399 | "eza_colors-explanation.5")) |
| 1395 | (add-after 'install 'install-extras | 1400 | (apply (assoc-ref copy:%standard-phases 'install) |
| 1396 | (lambda* (#:key outputs #:allow-other-keys) | 1401 | #:install-plan |
| 1397 | (let* ((out (assoc-ref outputs "out")) | 1402 | '(("eza.1" "share/man/man1/") |
| 1398 | (share (string-append out "/share")) | 1403 | ("eza_colors.5" "share/man/man5/") |
| 1399 | (bash-completions-dir | 1404 | ("eza_colors-explanation.5" "share/man/man5/")) |
| 1400 | (string-append share "/bash-completion/completions")) | 1405 | args)))) |
| 1401 | (zsh-completions-dir | 1406 | (add-after 'install 'install-completions |
| 1402 | (string-append share "/zsh/site-functions")) | 1407 | (lambda args |
| 1403 | (fish-completions-dir | 1408 | (apply (assoc-ref copy:%standard-phases 'install) |
| 1404 | (string-append share "/fish/vendor_completions.d")) | 1409 | #:install-plan |
| 1405 | (nu-completions-dir | 1410 | '(("completions/bash/eza" |
| 1406 | (string-append share "/nushell/vendor/autoload")) | 1411 | "share/bash-completion/completions/") |
| 1407 | (man1 (string-append share "/man/man1")) | 1412 | ("completions/fish/eza.fish" |
| 1408 | (man5 (string-append share "/man/man5"))) | 1413 | "share/fish/vendor_completions.d/") |
| 1409 | (when (file-exists? "eza.1") | 1414 | ("completions/nush/eza.nu" |
| 1410 | (install-file "eza.1" man1)) | 1415 | "share/nushell/vendor/autoload/") |
| 1411 | (when (file-exists? "eza_colors.5") | 1416 | ("completions/zsh/_eza" |
| 1412 | (install-file "eza_colors.5" man5)) | 1417 | "share/zsh/site-functions/")) |
| 1413 | (when (file-exists? "eza_colors-explanation.5") | 1418 | args)))))) |
| 1414 | (install-file "eza_colors-explanation.5" man5)) | ||
| 1415 | (install-file "completions/bash/eza" bash-completions-dir) | ||
| 1416 | (install-file "completions/zsh/_eza" zsh-completions-dir) | ||
| 1417 | (install-file "completions/fish/eza.fish" fish-completions-dir) | ||
| 1418 | (install-file "completions/nush/eza.nu" nu-completions-dir))))))) | ||
| 1419 | (native-inputs | 1419 | (native-inputs |
| 1420 | (append (list pkg-config) | 1420 | (append (list pkg-config) |
| 1421 | (if (supported-package? pandoc) | 1421 | (if (supported-package? pandoc) |
