1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 pythonAtLeast,
6
7 # build-system
8 setuptools,
9
10 # dependencies
11 build,
12 docutils,
13 flit-core,
14 packaging,
15 pygments,
16 requests,
17 trove-classifiers,
18
19 # test
20 pytestCheckHook,
21}:
22
23buildPythonPackage rec {
24 pname = "pyroma";
25 version = "4.2";
26 pyproject = true;
27
28 # https://github.com/regebro/pyroma/issues/104
29 disabled = pythonAtLeast "3.12";
30
31 src = fetchFromGitHub {
32 owner = "regebro";
33 repo = "pyroma";
34 rev = version;
35 sha256 = "sha256-ElSw+bY6fbHJPTX7O/9JZ4drttfbUQsU/fv3Cqqb/J4=";
36 };
37
38 propagatedBuildInputs = [
39 build
40 docutils
41 flit-core
42 packaging
43 pygments
44 setuptools
45 requests
46 trove-classifiers
47 ];
48
49 nativeCheckInputs = [ pytestCheckHook ];
50
51 disabledTests = [
52 # tries to reach pypi
53 "test_complete"
54 "test_distribute"
55 ];
56
57 pythonImportsCheck = [ "pyroma" ];
58
59 meta = with lib; {
60 description = "Test your project's packaging friendliness";
61 mainProgram = "pyroma";
62 homepage = "https://github.com/regebro/pyroma";
63 license = licenses.mit;
64 maintainers = with maintainers; [ kamadorueda ];
65 };
66}