2021-01-15 22:18:51 +00:00
|
|
|
{ lib, stdenv, fetchurl, makeWrapper, perl, perlPackages }:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2023-10-09 19:29:22 +00:00
|
|
|
version = "4.0";
|
2020-04-24 23:36:52 +00:00
|
|
|
pname = "kpcli";
|
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "mirror://sourceforge/kpcli/${pname}-${version}.pl";
|
2023-10-09 19:29:22 +00:00
|
|
|
sha256 = "sha256-UYnX2tad3Jg00kdX5WHStI6u2pyts+SZlgj/jv4o/TU=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-03-09 03:18:52 +00:00
|
|
|
nativeBuildInputs = [ makeWrapper ];
|
|
|
|
buildInputs = [ perl ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-07-24 12:14:16 +00:00
|
|
|
dontUnpack = true;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
mkdir -p $out/{bin,share}
|
|
|
|
cp ${src} $out/share/kpcli.pl
|
|
|
|
chmod +x $out/share/kpcli.pl
|
|
|
|
|
|
|
|
makeWrapper $out/share/kpcli.pl $out/bin/kpcli --set PERL5LIB \
|
|
|
|
"${with perlPackages; makePerlPath ([
|
|
|
|
CaptureTiny Clipboard Clone CryptRijndael SortNaturally TermReadKey TermShellUI FileKeePass TermReadLineGnu XMLParser
|
2021-01-15 22:18:51 +00:00
|
|
|
] ++ lib.optional stdenv.isDarwin MacPasteboard)}"
|
2020-04-24 23:36:52 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "KeePass Command Line Interface";
|
|
|
|
longDescription = ''
|
2021-01-15 22:18:51 +00:00
|
|
|
KeePass Command Line Interface (CLI) / interactive shell.
|
2020-04-24 23:36:52 +00:00
|
|
|
Use this program to access and manage your KeePass 1.x or 2.x databases from a Unix-like command line.
|
|
|
|
'';
|
|
|
|
license = licenses.artistic1;
|
|
|
|
homepage = "http://kpcli.sourceforge.net";
|
|
|
|
platforms = platforms.all;
|
|
|
|
maintainers = [ maintainers.j-keck ];
|
|
|
|
};
|
|
|
|
}
|