From e9e6d62c59573e250c518e59a097cdf35a471ff8 Mon Sep 17 00:00:00 2001 From: Moritz Ulrich Date: Fri, 4 Dec 2015 17:22:07 +0100 Subject: [PATCH] rofi-pass: 1.2 -> 1.3.1 Also contains fixes so it doesn't depend on anything in PATH. --- pkgs/applications/misc/rofi/pass.nix | 30 ---------------- pkgs/tools/security/pass/rofi-pass.nix | 49 ++++++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 +- 3 files changed, 50 insertions(+), 31 deletions(-) delete mode 100644 pkgs/applications/misc/rofi/pass.nix create mode 100644 pkgs/tools/security/pass/rofi-pass.nix diff --git a/pkgs/applications/misc/rofi/pass.nix b/pkgs/applications/misc/rofi/pass.nix deleted file mode 100644 index 7a8c9dfd71e..00000000000 --- a/pkgs/applications/misc/rofi/pass.nix +++ /dev/null @@ -1,30 +0,0 @@ -{ stdenv, fetchgit, rofi, wmctrl, xprop, xdotool}: - -stdenv.mkDerivation rec { - name = "rofi-pass-${version}"; - version = "1.2"; - - src = fetchgit { - url = "https://github.com/carnager/rofi-pass"; - rev = "refs/tags/${version}"; - sha256 = "1dlaplr18qady5g8sp8xgiqdw81mfx9iisihf8appr5s4sjm559h"; - }; - - buildInputs = [ rofi wmctrl xprop xdotool ]; - - dontBuild = true; - - installPhase = '' - mkdir -p $out/bin - cp -a $src/rofi-pass $out/bin/rofi-pass - - mkdir -p $out/share/doc/rofi-pass/ - cp -a $src/config.example $out/share/doc/rofi-pass/config.example - ''; - - meta = { - description = "A script to make rofi work with password-store"; - homepage = https://github.com/carnager/rofi-pass; - maintainers = [stdenv.lib.maintainers.hiberno]; - }; -} diff --git a/pkgs/tools/security/pass/rofi-pass.nix b/pkgs/tools/security/pass/rofi-pass.nix new file mode 100644 index 00000000000..98ef14cb578 --- /dev/null +++ b/pkgs/tools/security/pass/rofi-pass.nix @@ -0,0 +1,49 @@ +{ stdenv, fetchgit +, pass, rofi, coreutils, utillinux, xdotool, gnugrep +, makeWrapper }: + +stdenv.mkDerivation rec { + name = "rofi-pass-${version}"; + version = "1.3.1"; + + src = fetchgit { + url = "https://github.com/carnager/rofi-pass"; + rev = "refs/tags/${version}"; + sha256 = "1r206fq96avhlgkf2fzf8j2a25dav0s945qv66hwvqwhxq74frrv"; + }; + + buildInputs = [ makeWrapper ]; + + dontBuild = true; + + installPhase = '' + mkdir -p $out/bin + cp -a $src/rofi-pass $out/bin/rofi-pass + + mkdir -p $out/share/doc/rofi-pass/ + cp -a $src/config.example $out/share/doc/rofi-pass/config.example + ''; + + wrapperPath = with stdenv.lib; makeSearchPath "bin/" [ + coreutils + utillinux + rofi + pass + xdotool + gnugrep + ]; + + fixupPhase = '' + patchShebangs $out/bin + + wrapProgram $out/bin/rofi-pass \ + --prefix PATH : "${wrapperPath}" + ''; + + meta = { + description = "A script to make rofi work with password-store"; + homepage = https://github.com/carnager/rofi-pass; + maintainers = with stdenv.lib.maintainers; [ hiberno the-kenny ]; + license = stdenv.lib.licenses.gpl3; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index b04f43cd508..a6f70b0ae33 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -12884,7 +12884,7 @@ let automake = automake114x; }; - rofi-pass = callPackage ../applications/misc/rofi/pass.nix { }; + rofi-pass = callPackage ../tools/security/pass/rofi-pass.nix { }; rstudio = callPackage ../applications/editors/rstudio { };