lol
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

python313Packages.anybadge: fix build, modernize

+19 -8
+19 -8
pkgs/development/python-modules/anybadge/default.nix
··· 2 2 lib, 3 3 buildPythonPackage, 4 4 fetchFromGitHub, 5 + setuptools, 5 6 packaging, 6 7 pytestCheckHook, 7 8 pythonOlder, 8 9 requests, 10 + sh, 9 11 }: 10 12 11 13 buildPythonPackage rec { 12 14 pname = "anybadge"; 13 15 version = "1.16.0"; 14 - format = "setuptools"; 16 + pyproject = true; 15 17 16 18 disabled = pythonOlder "3.7"; 17 19 18 20 src = fetchFromGitHub { 19 21 owner = "jongracecox"; 20 - repo = pname; 22 + repo = "anybadge"; 21 23 tag = "v${version}"; 22 24 hash = "sha256-9qGmiIGzVdWHMyurMqTqEz+NKYlc/5zt6HPsssCH4Pk="; 23 25 }; 24 26 25 - # setup.py reads its version from the TRAVIS_TAG environment variable 26 - TRAVIS_TAG = "v${version}"; 27 + postPatch = '' 28 + substituteInPlace setup.py \ 29 + --replace-fail '=get_version(),' "='$version'," 30 + ''; 31 + 32 + build-system = [ 33 + setuptools 34 + ]; 27 35 28 - propagatedBuildInputs = [ packaging ]; 36 + dependencies = [ 37 + packaging 38 + ]; 29 39 30 40 nativeCheckInputs = [ 31 41 pytestCheckHook 32 42 requests 43 + sh 33 44 ]; 34 45 35 46 disabledTests = [ ··· 44 55 45 56 pythonImportsCheck = [ "anybadge" ]; 46 57 47 - meta = with lib; { 58 + meta = { 48 59 description = "Python tool for generating badges for your projects"; 49 60 homepage = "https://github.com/jongracecox/anybadge"; 50 61 changelog = "https://github.com/jongracecox/anybadge/releases/tag/${src.tag}"; 51 - license = licenses.mit; 52 - maintainers = with maintainers; [ fabiangd ]; 62 + license = lib.licenses.mit; 63 + maintainers = with lib.maintainers; [ fabiangd ]; 53 64 }; 54 65 }