gnu: bash-completion: Modify to modify-phases.
* gnu/packages/bash.scm (bash-completion): Use modify-phases instead of alist-cons-after.master
parent
cccb4d2652
commit
aa67d3c546
|
@ -289,29 +289,29 @@ without modification.")
|
||||||
(build-system gnu-build-system)
|
(build-system gnu-build-system)
|
||||||
(native-inputs `(("util-linux" ,util-linux)))
|
(native-inputs `(("util-linux" ,util-linux)))
|
||||||
(arguments
|
(arguments
|
||||||
`(#:phases (alist-cons-after
|
`(#:phases (modify-phases %standard-phases
|
||||||
'install 'remove-redundant-completions
|
(add-after
|
||||||
(lambda* (#:key inputs outputs #:allow-other-keys)
|
'install 'remove-redundant-completions
|
||||||
;; Util-linux comes with a bunch of completion files for
|
(lambda* (#:key inputs outputs #:allow-other-keys)
|
||||||
;; its own commands which are more sophisticated and
|
;; Util-linux comes with a bunch of completion files for
|
||||||
;; up-to-date than those of bash-completion. Remove those
|
;; its own commands which are more sophisticated and
|
||||||
;; from bash-completion.
|
;; up-to-date than those of bash-completion. Remove those
|
||||||
(let* ((out (assoc-ref outputs "out"))
|
;; from bash-completion.
|
||||||
(util-linux (assoc-ref inputs "util-linux"))
|
(let* ((out (assoc-ref outputs "out"))
|
||||||
(completions (string-append out
|
(util-linux (assoc-ref inputs "util-linux"))
|
||||||
"/share/bash-completion"
|
(completions (string-append out
|
||||||
"/completions"))
|
"/share/bash-completion"
|
||||||
(already (find-files
|
"/completions"))
|
||||||
(string-append
|
(already (find-files
|
||||||
util-linux
|
(string-append
|
||||||
"/etc/bash_completion.d"))))
|
util-linux
|
||||||
(with-directory-excursion completions
|
"/etc/bash_completion.d"))))
|
||||||
(for-each (lambda (file)
|
(with-directory-excursion completions
|
||||||
(when (file-exists? file)
|
(for-each (lambda (file)
|
||||||
(delete-file file)))
|
(when (file-exists? file)
|
||||||
(map basename already)))
|
(delete-file file)))
|
||||||
#t))
|
(map basename already)))
|
||||||
%standard-phases)))
|
#t))))))
|
||||||
(synopsis "Bash completions for common commands")
|
(synopsis "Bash completions for common commands")
|
||||||
(description
|
(description
|
||||||
"This package provides extensions that allow Bash to provide adapted
|
"This package provides extensions that allow Bash to provide adapted
|
||||||
|
|
Loading…
Reference in New Issue