2019-07-22 12:02:47 +00:00
|
|
|
{ stdenv, lib, bundlerEnv, ruby, bundlerUpdateScript, xsel, makeWrapper }:
|
2016-04-24 23:55:07 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2021-07-20 16:26:48 +00:00
|
|
|
pname = "pws";
|
|
|
|
version = (import ./gemset.nix).pws.version;
|
2016-04-24 23:55:07 +00:00
|
|
|
|
2021-02-07 09:17:39 +00:00
|
|
|
nativeBuildInputs = [ makeWrapper ];
|
2016-04-24 23:55:07 +00:00
|
|
|
|
2021-07-20 15:02:35 +00:00
|
|
|
dontUnpack = true;
|
2016-04-24 23:55:07 +00:00
|
|
|
|
2019-11-10 01:13:39 +00:00
|
|
|
installPhase = let
|
|
|
|
env = bundlerEnv {
|
2021-07-20 16:26:48 +00:00
|
|
|
name = "${pname}-gems";
|
2019-11-10 01:13:39 +00:00
|
|
|
|
|
|
|
inherit ruby;
|
|
|
|
|
|
|
|
gemdir = ./.;
|
|
|
|
};
|
|
|
|
in ''
|
2016-04-24 23:55:07 +00:00
|
|
|
mkdir -p $out/bin
|
|
|
|
makeWrapper ${env}/bin/pws $out/bin/pws \
|
|
|
|
--set PATH '"${xsel}/bin/:$PATH"'
|
|
|
|
'';
|
|
|
|
|
2019-07-22 12:02:47 +00:00
|
|
|
passthru.updateScript = bundlerUpdateScript "pws";
|
|
|
|
|
2016-04-24 23:55:07 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Command-line password safe";
|
2020-04-01 01:11:51 +00:00
|
|
|
homepage = "https://github.com/janlelis/pws";
|
2016-04-24 23:55:07 +00:00
|
|
|
license = licenses.mit;
|
2019-07-22 12:02:47 +00:00
|
|
|
maintainers = with maintainers; [ swistak35 nicknovitski ];
|
2016-04-24 23:55:07 +00:00
|
|
|
platforms = platforms.unix;
|
|
|
|
};
|
|
|
|
}
|