about summary refs log tree commit diff
path: root/pkgs/development/python-modules/cons/default.nix
blob: d08f5deb3c96d3f2a87e0fa79e36abd4689cea39 (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
, fetchFromGitHub
, logical-unification
, py
, pytestCheckHook
, pytest-html
, pythonOlder
}:

buildPythonPackage rec {
  pname = "cons";
  version = "0.4.6";
  format = "setuptools";

  disabled = pythonOlder "3.7";

  src = fetchFromGitHub {
    owner = "pythological";
    repo = "python-cons";
    rev = "refs/tags/v${version}";
    hash = "sha256-XssERKiv4A8x7dZhLeFSciN6RCEfGs0or3PAQiYSPII=";
  };

  propagatedBuildInputs = [
    logical-unification
  ];

  nativeCheckInputs = [
    py
    pytestCheckHook
    pytest-html
  ];

  pytestFlagsArray = [
    "--html=testing-report.html"
    "--self-contained-html"
  ];

  pythonImportsCheck = [ "cons" ];

  meta = with lib; {
    description = "An implementation of Lisp/Scheme-like cons in Python";
    homepage = "https://github.com/pythological/python-cons";
    changelog = "https://github.com/pythological/python-cons/releases/tag/v${version}";
    license = licenses.gpl3Only;
    maintainers = with maintainers; [ Etjean ];
  };
}