about summary refs log tree commit diff
path: root/pkgs/development/python-modules/ansible-vault-rw/default.nix
blob: 1a772b3c639f975979a939977e5adf25a2f13f26 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
{
  lib,
  buildPythonPackage,
  fetchPypi,

  # build-system
  setuptools,

  # dependencies
  ansible-core,

  # tests
  pytestCheckHook,
}:

buildPythonPackage rec {
  pname = "ansible-vault-rw";
  version = "2.1.0";
  pyproject = true;

  src = fetchPypi {
    pname = "ansible-vault";
    inherit version;
    hash = "sha256-XOj9tUcPFEm3a/B64qvFZIDa1INWrkBchbaG77ZNvV4";
  };

  nativeBuildInputs = [ setuptools ];

  propagatedBuildInputs = [ ansible-core ];

  # Otherwise tests will fail to create directory
  # Permission denied: '/homeless-shelter'
  preCheck = ''
    export HOME=$(mktemp -d)
  '';

  # no tests in sdist, no 2.1.0 tag on git
  doCheck = false;

  nativeCheckInputs = [ pytestCheckHook ];

  meta = with lib; {
    description = "This project aim to R/W an ansible-vault yaml file";
    homepage = "https://github.com/tomoh1r/ansible-vault";
    changelog = "https://github.com/tomoh1r/ansible-vault/blob/master/CHANGES.txt";
    license = licenses.gpl3;
    maintainers = with maintainers; [ StillerHarpo ];
  };
}