pass: seperate dmenu from x11Support
This commit is contained in:
parent
b3a8771443
commit
118695a350
@ -3,7 +3,7 @@
|
|||||||
, qrencode , makeWrapper, pass, symlinkJoin
|
, qrencode , makeWrapper, pass, symlinkJoin
|
||||||
|
|
||||||
, xclip ? null, xdotool ? null, dmenu ? null
|
, xclip ? null, xdotool ? null, dmenu ? null
|
||||||
, x11Support ? !stdenv.isDarwin
|
, x11Support ? !stdenv.isDarwin , dmenuSupport ? x11Support
|
||||||
, waylandSupport ? false, wl-clipboard ? null
|
, waylandSupport ? false, wl-clipboard ? null
|
||||||
|
|
||||||
# For backwards-compatibility
|
# For backwards-compatibility
|
||||||
@ -12,9 +12,11 @@
|
|||||||
|
|
||||||
with lib;
|
with lib;
|
||||||
|
|
||||||
assert x11Support -> xclip != null
|
assert x11Support -> xclip != null;
|
||||||
|
|
||||||
|
assert dmenuSupport -> dmenu != null
|
||||||
&& xdotool != null
|
&& xdotool != null
|
||||||
&& dmenu != null;
|
&& x11Support;
|
||||||
|
|
||||||
assert waylandSupport -> wl-clipboard != null;
|
assert waylandSupport -> wl-clipboard != null;
|
||||||
|
|
||||||
@ -72,7 +74,7 @@ stdenv.mkDerivation rec {
|
|||||||
# himself.
|
# himself.
|
||||||
mkdir -p "$out/share/emacs/site-lisp"
|
mkdir -p "$out/share/emacs/site-lisp"
|
||||||
cp "contrib/emacs/password-store.el" "$out/share/emacs/site-lisp/"
|
cp "contrib/emacs/password-store.el" "$out/share/emacs/site-lisp/"
|
||||||
'' + optionalString x11Support ''
|
'' + optionalString dmenuSupport ''
|
||||||
cp "contrib/dmenu/passmenu" "$out/bin/"
|
cp "contrib/dmenu/passmenu" "$out/bin/"
|
||||||
'';
|
'';
|
||||||
|
|
||||||
@ -87,7 +89,8 @@ stdenv.mkDerivation rec {
|
|||||||
qrencode
|
qrencode
|
||||||
procps
|
procps
|
||||||
] ++ optional stdenv.isDarwin openssl
|
] ++ optional stdenv.isDarwin openssl
|
||||||
++ ifEnable x11Support [ dmenu xclip xdotool ]
|
++ optional x11Support xclip
|
||||||
|
++ optionals dmenuSupport [ xdotool dmenu ]
|
||||||
++ optional waylandSupport wl-clipboard);
|
++ optional waylandSupport wl-clipboard);
|
||||||
|
|
||||||
postFixup = ''
|
postFixup = ''
|
||||||
@ -98,7 +101,7 @@ stdenv.mkDerivation rec {
|
|||||||
# Ensure all dependencies are in PATH
|
# Ensure all dependencies are in PATH
|
||||||
wrapProgram $out/bin/pass \
|
wrapProgram $out/bin/pass \
|
||||||
--prefix PATH : "${wrapperPath}"
|
--prefix PATH : "${wrapperPath}"
|
||||||
'' + stdenv.lib.optionalString x11Support ''
|
'' + stdenv.lib.optionalString dmenuSupport ''
|
||||||
# We just wrap passmenu with the same PATH as pass. It doesn't
|
# We just wrap passmenu with the same PATH as pass. It doesn't
|
||||||
# need all the tools in there but it doesn't hurt either.
|
# need all the tools in there but it doesn't hurt either.
|
||||||
wrapProgram $out/bin/passmenu \
|
wrapProgram $out/bin/passmenu \
|
||||||
|
@ -1253,6 +1253,11 @@ in
|
|||||||
|
|
||||||
pass = callPackage ../tools/security/pass { };
|
pass = callPackage ../tools/security/pass { };
|
||||||
|
|
||||||
|
pass-nodmenu = callPackage ../tools/security/pass {
|
||||||
|
dmenuSupport = false;
|
||||||
|
pass = pass-nodmenu;
|
||||||
|
};
|
||||||
|
|
||||||
pass-wayland = callPackage ../tools/security/pass {
|
pass-wayland = callPackage ../tools/security/pass {
|
||||||
waylandSupport = true;
|
waylandSupport = true;
|
||||||
pass = pass-wayland;
|
pass = pass-wayland;
|
||||||
|
Loading…
Reference in New Issue
Block a user