Unverified Commit 77581438 authored by natsukium's avatar natsukium
Browse files

pass-git-helper: modernize

parent dcc4fd6a
Loading
Loading
Loading
Loading
+15 −6
Original line number Diff line number Diff line
{ lib, buildPythonApplication, fetchFromGitHub, pyxdg, pytest, pytest-mock }:
{ lib, buildPythonApplication, fetchFromGitHub, pyxdg, pytestCheckHook, pytest-cov-stub, pytest-mock, setuptools }:

buildPythonApplication rec {
  pname   = "pass-git-helper";
  version = "3.0.0";
  pyproject = true;

  src = fetchFromGitHub {
    owner  = "languitar";
@@ -11,11 +12,19 @@ buildPythonApplication rec {
    sha256 = "sha256-DLH3l4wYfBlrc49swLgyHeZXebJ5JSzU7cHjD7Hmw0g=";
  };

  propagatedBuildInputs = [ pyxdg ];
  nativeCheckInputs = [ pytest pytest-mock ];
  preCheck = ''
    export HOME=$(mktemp -d)
  '';
  build-system = [ setuptools ];

  dependencies = [ pyxdg ];

  env.HOME = "$TMPDIR";

  pythonImportsCheck = [ "passgithelper" ];

  nativeCheckInputs = [
    pytestCheckHook
    pytest-cov-stub
    pytest-mock
  ];

  meta = with lib; {
    homepage = "https://github.com/languitar/pass-git-helper";