gnu: password-store: Update to 1.7.3-1.918992c.

* gnu/packages/password-utils.scm (password-store): Update to
1.7.3-1.918992c.
[arguments]<#:phases>['wrap-path]: Add "wl-clipboard".
[inputs]: Add "wl-clipboard".

Signed-off-by: Tobias Geerinckx-Rice <me@tobias.gr>
This commit is contained in:
Sébastien Lerique 2021-03-07 22:15:26 +09:00 committed by Tobias Geerinckx-Rice
parent 5d0f394b85
commit 81404a858c
No known key found for this signature in database
GPG key ID: 0DB0FF884F556D79

View file

@ -516,93 +516,100 @@ (define-public assword
(license license:gpl3+))) (license license:gpl3+)))
(define-public password-store (define-public password-store
(package ;; The 1.7.3 release does not include support for wl-clipboard, which was
(name "password-store") ;; added in b0b784b1a57c0b06936e6f5d6560712b4b810cd3. Instead, use the
(version "1.7.3") ;; latest commit on master at the time of writing.
(source (origin (let ((commit "918992c19231b33b3d4a3288a7288a620e608cb4")
(method url-fetch) (revision "1"))
(uri (package
(string-append "https://git.zx2c4.com/password-store/snapshot/" (name "password-store")
name "-" version ".tar.xz")) (version (git-version "1.7.3" revision commit))
(sha256 (source (origin
(base32 (method git-fetch)
"1x53k5dn3cdmvy8m4fqdld4hji5n676ksl0ql4armkmsds26av1b")))) (uri (git-reference
(build-system gnu-build-system) (url "git://git.zx2c4.com/password-store")
(arguments (commit commit)))
'(#:phases (sha256
(modify-phases %standard-phases (base32
(delete 'configure) "0ni62f4pq96g0i0q66bch1dl9k4zqwhg7xaf746k3gbbqxcdh3vi"))
(delete 'build) (file-name (git-file-name name version)) ))
(add-before 'install 'patch-system-extension-dir (build-system gnu-build-system)
(lambda* (#:key outputs #:allow-other-keys) (arguments
(let* ((out (assoc-ref outputs "out")) '(#:phases
(extension-dir (string-append out "/lib/password-store/extensions"))) (modify-phases %standard-phases
(substitute* "src/password-store.sh" (delete 'configure)
(("^SYSTEM_EXTENSION_DIR=.*$") (delete 'build)
;; lead with whitespace to prevent 'make install' from (add-before 'install 'patch-system-extension-dir
;; overwriting it again (lambda* (#:key outputs #:allow-other-keys)
(string-append " SYSTEM_EXTENSION_DIR=\"" (let* ((out (assoc-ref outputs "out"))
"${PASSWORD_STORE_SYSTEM_EXTENSION_DIR:-" (extension-dir (string-append out "/lib/password-store/extensions")))
extension-dir (substitute* "src/password-store.sh"
"}\"\n")))) (("^SYSTEM_EXTENSION_DIR=.*$")
#t)) ;; lead with whitespace to prevent 'make install' from
(add-before 'install 'patch-passmenu-path ;; overwriting it again
(lambda* (#:key inputs #:allow-other-keys) (string-append " SYSTEM_EXTENSION_DIR=\""
(substitute* "contrib/dmenu/passmenu" "${PASSWORD_STORE_SYSTEM_EXTENSION_DIR:-"
(("dmenu") (string-append (assoc-ref inputs "dmenu") extension-dir
"/bin/dmenu")) "}\"\n"))))
(("xdotool") (string-append (assoc-ref inputs "xdotool") #t))
"/bin/xdotool"))) (add-before 'install 'patch-passmenu-path
#t)) (lambda* (#:key inputs #:allow-other-keys)
(add-after 'install 'install-passmenu (substitute* "contrib/dmenu/passmenu"
(lambda* (#:key outputs #:allow-other-keys) (("dmenu") (string-append (assoc-ref inputs "dmenu")
(let* ((out (assoc-ref outputs "out")) "/bin/dmenu"))
(bin (string-append out "/bin"))) (("xdotool") (string-append (assoc-ref inputs "xdotool")
(install-file "contrib/dmenu/passmenu" bin) "/bin/xdotool")))
#t))) #t))
(add-after 'install 'wrap-path (add-after 'install 'install-passmenu
(lambda* (#:key inputs outputs #:allow-other-keys) (lambda* (#:key outputs #:allow-other-keys)
(let ((out (assoc-ref outputs "out")) (let* ((out (assoc-ref outputs "out"))
(path (map (lambda (pkg) (bin (string-append out "/bin")))
(string-append (assoc-ref inputs pkg) "/bin")) (install-file "contrib/dmenu/passmenu" bin)
'("coreutils" "getopt" "git" "gnupg" "qrencode" #t)))
"sed" "tree" "which" "xclip")))) (add-after 'install 'wrap-path
(wrap-program (string-append out "/bin/pass") (lambda* (#:key inputs outputs #:allow-other-keys)
`("PATH" ":" prefix (,(string-join path ":")))) (let ((out (assoc-ref outputs "out"))
#t)))) (path (map (lambda (pkg)
#:make-flags (list "CC=gcc" (string-append "PREFIX=" %output) (string-append (assoc-ref inputs pkg) "/bin"))
"WITH_ALLCOMP=yes" '("coreutils" "getopt" "git" "gnupg" "qrencode"
(string-append "BASHCOMPDIR=" "sed" "tree" "which" "wl-clipboard" "xclip"))))
%output "/etc/bash_completion.d")) (wrap-program (string-append out "/bin/pass")
;; Parallel tests may cause a race condition leading to a `("PATH" ":" prefix (,(string-join path ":"))))
;; timeout in some circumstances. #t))))
#:parallel-tests? #f #:make-flags (list "CC=gcc" (string-append "PREFIX=" %output)
#:test-target "test")) "WITH_ALLCOMP=yes"
(native-search-paths (string-append "BASHCOMPDIR="
(list (search-path-specification %output "/etc/bash_completion.d"))
(variable "PASSWORD_STORE_SYSTEM_EXTENSION_DIR") ;; Parallel tests may cause a race condition leading to a
(separator #f) ;single entry ;; timeout in some circumstances.
(files '("lib/password-store/extensions"))))) #:parallel-tests? #f
(inputs #:test-target "test"))
`(("dmenu" ,dmenu) (native-search-paths
("getopt" ,util-linux) (list (search-path-specification
("git" ,git) (variable "PASSWORD_STORE_SYSTEM_EXTENSION_DIR")
("gnupg" ,gnupg) (separator #f) ;single entry
("qrencode" ,qrencode) (files '("lib/password-store/extensions")))))
("sed" ,sed) (inputs
("tree" ,tree) `(("dmenu" ,dmenu)
("which" ,which) ("getopt" ,util-linux)
("xclip" ,xclip) ("git" ,git)
("xdotool" ,xdotool))) ("gnupg" ,gnupg)
(home-page "https://www.passwordstore.org/") ("qrencode" ,qrencode)
(synopsis "Encrypted password manager") ("sed" ,sed)
(description "Password-store is a password manager which uses GnuPG to ("tree" ,tree)
("which" ,which)
("wl-clipboard" ,wl-clipboard)
("xclip" ,xclip)
("xdotool" ,xdotool)))
(home-page "https://www.passwordstore.org/")
(synopsis "Encrypted password manager")
(description "Password-store is a password manager which uses GnuPG to
store and retrieve passwords. The tool stores each password in its own store and retrieve passwords. The tool stores each password in its own
GnuPG-encrypted file, allowing the program to be simple yet secure. GnuPG-encrypted file, allowing the program to be simple yet secure.
Synchronization is possible using the integrated git support, which commits Synchronization is possible using the integrated git support, which commits
changes to your password database to a git repository that can be managed changes to your password database to a git repository that can be managed
through the pass command.") through the pass command.")
(license license:gpl2+))) (license license:gpl2+))))
(define-public pass-otp (define-public pass-otp
(package (package