From 983a63bac20b43a0431ea13feddcc0ef4ae2d44d Mon Sep 17 00:00:00 2001 From: Tad Fisher Date: Thu, 15 Nov 2018 12:12:14 -0800 Subject: Update Nix instructions --- README.md | 26 ++++++-------------------- 1 file changed, 6 insertions(+), 20 deletions(-) diff --git a/README.md b/README.md index efdc2ba..acd0b47 100644 --- a/README.md +++ b/README.md @@ -137,31 +137,17 @@ apt install pass-extension-otp emerge app-admin/pass-otp ``` -### NixOS +### Nix/NixOS -- `configuration.nix` - -System-wide: - -```nix -{ - environment.systemPackages = [ pkgs.pass-otp ]; -} -``` - -Per-user: +The following expression builds `pass` with the `pass-otp` extension: ```nix -{ - users.users."name".packages = [ pkgs.pass-otp ]; -} +with pkgs; +pass.withExtensions (exts: [ exts.pass-otp ]) ``` -- Imperative - -``` -nix-env -i pass-otp -``` +The above can be installed imperatively via `nix-env` or ran in a temprorary +environment via `nix-shell`. ### macOS #### Brew -- cgit v1.2.3