summary refs log tree commit diff
path: root/pkgs/tools/security/pass
diff options
context:
space:
mode:
authorPeter Hoeg <peter@hoeg.com>2017-07-19 09:18:06 +0800
committerGitHub <noreply@github.com>2017-07-19 09:18:06 +0800
commite760337a22bc0531e54228e21cfaeede3572f74f (patch)
tree41794f19cc86af14d84e4ed226ee9845280d17aa /pkgs/tools/security/pass
parent0bf019c99a707a23d279d196ff9c463175f4a5a6 (diff)
parentfd5e201bf2270073b1c02076447c0843caa09f07 (diff)
downloadnixpkgs-e760337a22bc0531e54228e21cfaeede3572f74f.tar
nixpkgs-e760337a22bc0531e54228e21cfaeede3572f74f.tar.gz
nixpkgs-e760337a22bc0531e54228e21cfaeede3572f74f.tar.bz2
nixpkgs-e760337a22bc0531e54228e21cfaeede3572f74f.tar.lz
nixpkgs-e760337a22bc0531e54228e21cfaeede3572f74f.tar.xz
nixpkgs-e760337a22bc0531e54228e21cfaeede3572f74f.tar.zst
nixpkgs-e760337a22bc0531e54228e21cfaeede3572f74f.zip
Merge pull request #26393 from peterhoeg/f/pass
pass: add plugins to support importing and updating
Diffstat (limited to 'pkgs/tools/security/pass')
-rw-r--r--pkgs/tools/security/pass/default.nix21
1 files changed, 19 insertions, 2 deletions
diff --git a/pkgs/tools/security/pass/default.nix b/pkgs/tools/security/pass/default.nix
index baa53492d3e..331a75495ed 100644
--- a/pkgs/tools/security/pass/default.nix
+++ b/pkgs/tools/security/pass/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, lib, fetchurl
+{ stdenv, lib, fetchurl, fetchFromGitHub
 , coreutils, gnused, getopt, git, tree, gnupg, which, procps, qrencode
 , makeWrapper
 
@@ -12,7 +12,17 @@ assert x11Support -> xclip != null
                   && xdotool != null
                   && dmenu != null;
 
-stdenv.mkDerivation rec {
+let
+  plugins = map (p: (fetchFromGitHub {
+    owner  = "roddhjav";
+    repo   = "pass-${p.name}";
+    inherit (p) rev sha256;
+  })) [
+    { name = "import"; rev = "491935bd275f29ceac2b876b3a288011d1ce31e7"; sha256 = "02mbh05ab8h7kc30hz718d1d1vkjz43b96c7p0xnd92610d2q66q"; }
+    { name = "update"; rev = "cf576c9036fd18efb9ed29e0e9f811207b556fde"; sha256 = "1hhbrg6a2walrvla6q4cd3pgrqbcrf9brzjkb748735shxfn52hd"; }
+  ];
+
+in stdenv.mkDerivation rec {
   version = "1.7.1";
   name    = "password-store-${version}";
 
@@ -29,6 +39,13 @@ stdenv.mkDerivation rec {
   installFlags = [ "PREFIX=$(out)" "WITH_ALLCOMP=yes" ];
 
   postInstall = ''
+    # plugins
+    ${stdenv.lib.concatStringsSep "\n" (map (plugin: ''
+      pushd ${plugin}
+      PREFIX=$out make install
+      popd
+    '') plugins)}
+
     # Install Emacs Mode. NOTE: We can't install the necessary
     # dependencies (s.el and f.el) here. The user has to do this
     # himself.