Merge pull request #119571 from hennersz/fix/pass-import-install-extension

passExtensions.pass-import: install extension script and completion
This commit is contained in:
Domen Kožar 2021-06-02 17:33:18 +02:00 committed by GitHub
commit bf00839d04
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -4,6 +4,7 @@
, python3Packages
, gnupg
, pass
, makeWrapper
}:
python3Packages.buildPythonApplication rec {
@ -55,6 +56,16 @@ python3Packages.buildPythonApplication rec {
$out/bin/pimport --list-exporters --list-importers
'';
postInstall = ''
mkdir -p $out/lib/password-store/extensions
cp ${src}/scripts/import.bash $out/lib/password-store/extensions/import.bash
wrapProgram $out/lib/password-store/extensions/import.bash \
--prefix PATH : "${python3Packages.python.withPackages(_: propagatedBuildInputs)}/bin" \
--prefix PYTHONPATH : "$out/${python3Packages.python.sitePackages}" \
--run "export PREFIX"
cp -r ${src}/share $out/
'';
meta = with lib; {
description = "Pass extension for importing data from existing password managers";
homepage = "https://github.com/roddhjav/pass-import";