From 593c07eb666806ecdcbb58bb5c64a4b94bd5b7a9 Mon Sep 17 00:00:00 2001 From: Dmitriy Pleshevskiy Date: Sun, 17 Apr 2022 00:35:27 +0300 Subject: [PATCH] feat(nix/prog/pass): add pass with gnupg --- nix/home.nix | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) diff --git a/nix/home.nix b/nix/home.nix index d24d978..91659de 100644 --- a/nix/home.nix +++ b/nix/home.nix @@ -49,6 +49,7 @@ in xh # friendly and fast tool for sending HTTP requests fd # a simple, fast and user-friendly alternative to find bat # a cat clone with syntax highlighting and git integration + pass # cli password manager # haskell stylish-haskell # formatter @@ -60,9 +61,16 @@ in librewolf # a fork of firefox, focused on privacy, security and freedom ]; - home.sessionVariables = { - EDITOR = "nvim"; - }; + home.sessionVariables = + let + pass_data_dir = "${config.home.sessionVariables.XDG_DATA_HOME}/pass"; + in + { + EDITOR = "nvim"; + # for 'pass' tool + PASSWORD_STORE_DIR = "${pass_data_dir}/store"; + PASSWORD_STORE_EXTENSIONS_DIR = "${pass_data_dir}/extensions"; + }; xsession = { enable = true; @@ -97,9 +105,14 @@ in inactiveInterval = 5; }; + services.gpg-agent.enable = true; + # Let Home Manager install and manage itself. programs.home-manager.enable = true; + # used for pass + programs.gpg.enable = true; + # enable z shell programs.zsh = { enable = true;