1{ lib
2, buildPythonPackage
3, fetchFromGitHub
4, packaging
5, pytestCheckHook
6, pythonOlder
7, requests
8}:
9
10buildPythonPackage rec {
11 pname = "anybadge";
12 version = "1.14.0";
13 format = "setuptools";
14
15 disabled = pythonOlder "3.7";
16
17 src = fetchFromGitHub {
18 owner = "jongracecox";
19 repo = pname;
20 rev = "refs/tags/v${version}";
21 hash = "sha256-+CkkFCShCYtxKiCWRQcgTFcekc/g7ujQj9MdnG1+a0A=";
22 };
23
24 # setup.py reads its version from the TRAVIS_TAG environment variable
25 TRAVIS_TAG = "v${version}";
26
27 propagatedBuildInputs = [
28 packaging
29 ];
30
31 nativeCheckInputs = [
32 pytestCheckHook
33 requests
34 ];
35
36 disabledTests = [
37 # Comparison of CLI output fails
38 "test_module_same_output_as_main_cli"
39 ];
40
41 disabledTestPaths = [
42 # No anybadge-server
43 "tests/test_server.py"
44 ];
45
46 pythonImportsCheck = [
47 "anybadge"
48 ];
49
50 meta = with lib; {
51 description = "Python tool for generating badges for your projects";
52 homepage = "https://github.com/jongracecox/anybadge";
53 changelog = "https://github.com/jongracecox/anybadge/releases/tag/v${version}";
54 license = licenses.mit;
55 maintainers = with maintainers; [ fabiangd ];
56 };
57}