diff options
author | Samy Lahfa <14914796+AkechiShiro@users.noreply.github.com> | 2023-11-25 02:28:39 +0100 |
---|---|---|
committer | Lahfa Samy <14914796+AkechiShiro@users.noreply.github.com> | 2023-11-26 02:45:07 +0100 |
commit | 76c0d6b39b40661fa2eea9737c709aa411c3128d (patch) | |
tree | 6030f9eb752fb01002165ecbac4cbf0098aaed3d /pkgs/tools/security/pass | |
parent | ed0f304e3329cbd272cebc83cef712f9dba71328 (diff) |
wofi-pass: init at 23.1.2
* Fix URL type to a string * Add extension option and replace cp by install -Dm755 * use nativeBuildInputs instead of buildInputs * Add install -t option * Remove useless mkdir * Use let in construct for wrapperPath and clean exts declaration * Add meta.mainProgram
Diffstat (limited to 'pkgs/tools/security/pass')
-rw-r--r-- | pkgs/tools/security/pass/wofi-pass.nix | 65 |
1 files changed, 65 insertions, 0 deletions
diff --git a/pkgs/tools/security/pass/wofi-pass.nix b/pkgs/tools/security/pass/wofi-pass.nix new file mode 100644 index 0000000000000..f205d8881e516 --- /dev/null +++ b/pkgs/tools/security/pass/wofi-pass.nix @@ -0,0 +1,65 @@ +{ lib +, stdenv +, fetchFromGitHub +, pass-wayland +, coreutils +, gnugrep +, libnotify +, pwgen +, findutils +, makeWrapper +, wl-clipboard +, wtype +, wofi +, extensions ? exts: [] +}: + +let + wrapperPath = lib.makeBinPath [ + coreutils + findutils + gnugrep + libnotify + pwgen + wofi + wl-clipboard + wtype + (pass-wayland.withExtensions extensions) + ]; +in +stdenv.mkDerivation rec { + pname = "wofi-pass"; + version = "23.1.2"; + + src = fetchFromGitHub { + owner = "schmidtandreas"; + repo = "wofi-pass"; + rev = "v${version}"; + sha256 = "sha256-Z1a+nfnL6NXhufpCU7VIkwuifoS88Pf9qI8GCuP/Zqc="; + }; + + nativeBuildInputs = [ makeWrapper ]; + + dontBuild = true; + + installPhase = '' + install -Dm755 wofi-pass -t $out/bin + install -Dm755 wofi-pass.conf -t $out/share/doc/wofi-pass/wofi-pass.conf + ''; + + fixupPhase = '' + patchShebangs $out/bin + + wrapProgram $out/bin/wofi-pass \ + --prefix PATH : "${wrapperPath}" + ''; + + meta = { + description = "A script to make wofi work with password-store"; + homepage = "https://github.com/schmidtandreas/wofi-pass"; + maintainers = with lib.maintainers; [ akechishiro ]; + license = lib.licenses.gpl2Plus; + platforms = with lib.platforms; linux; + mainProgram = "wofi-pass"; + }; +} |