diff options
author | Adrian Kummerlaender | 2020-02-29 11:15:05 +0100 |
---|---|---|
committer | Adrian Kummerlaender | 2020-02-29 11:15:05 +0100 |
commit | 21209a2fcedcab9a87eb1269976cf59a4dc51e61 (patch) | |
tree | 05ad1a113065d427d59a379eb1698def425afa17 | |
parent | d5bf025a4db2f8b06b89429203042aad15dc1a5a (diff) | |
download | nixos_home-21209a2fcedcab9a87eb1269976cf59a4dc51e61.tar nixos_home-21209a2fcedcab9a87eb1269976cf59a4dc51e61.tar.gz nixos_home-21209a2fcedcab9a87eb1269976cf59a4dc51e61.tar.bz2 nixos_home-21209a2fcedcab9a87eb1269976cf59a4dc51e61.tar.lz nixos_home-21209a2fcedcab9a87eb1269976cf59a4dc51e61.tar.xz nixos_home-21209a2fcedcab9a87eb1269976cf59a4dc51e61.tar.zst nixos_home-21209a2fcedcab9a87eb1269976cf59a4dc51e61.zip |
Add rofi selector for pass
-rw-r--r-- | gui/conf/xmonad.hs | 3 | ||||
-rw-r--r-- | gui/default.nix | 1 | ||||
-rw-r--r-- | gui/pass.nix | 32 | ||||
-rw-r--r-- | home.nix | 1 |
4 files changed, 36 insertions, 1 deletions
diff --git a/gui/conf/xmonad.hs b/gui/conf/xmonad.hs index 5038f48..1505f6f 100644 --- a/gui/conf/xmonad.hs +++ b/gui/conf/xmonad.hs @@ -166,6 +166,9 @@ commonKeybindings host = , ("M-S-<Return>" , spawn "nvim-qt --no-ext-tabline") , ("<Print>" , spawn "flameshot gui") +-- password management + , ("M-p" , spawn "passrofi") + -- window management , ("M-q" , windows $ S.shift "NSP") , ("M-S-q" , kill) diff --git a/gui/default.nix b/gui/default.nix index 971afd1..8640143 100644 --- a/gui/default.nix +++ b/gui/default.nix @@ -10,6 +10,7 @@ in { ./vim.nix ./emacs.nix ./zathura.nix + ./pass.nix # applications grouped by purpose ./apps/file.nix ./apps/web.nix diff --git a/gui/pass.nix b/gui/pass.nix new file mode 100644 index 0000000..3c8331d --- /dev/null +++ b/gui/pass.nix @@ -0,0 +1,32 @@ +{ config, pkgs, ... }: + +let + emumenu = pkgs.writeTextFile { + name = "emumenu"; + executable = true; + destination = "/bin/dmenu"; + + text = '' + #!/usr/bin/env bash + ${pkgs.rofi}/bin/rofi -dmenu -p "pass" "$@" + ''; + }; + + passrofi = pkgs.writeTextFile { + name = "passrofi"; + executable = true; + destination = "/bin/passrofi"; + + text = '' + #!/usr/bin/env bash + export PATH="$PATH:${emumenu}/bin" + ${pkgs.pass}/bin/.passmenu-wrapped + ''; + }; + +in { + home.packages = [ + pkgs.pass + passrofi + ]; +} @@ -18,7 +18,6 @@ keyboard.layout = "de"; packages = [ - pkgs.pass config.custom.pkgs.persistent-nix-shell ]; }; |