1{ 2 lib, 3 buildPythonPackage, 4 pythonOlder, 5 fetchPypi, 6 packaging, 7 tomli, 8 coverage, 9 pytestCheckHook, 10 build, 11 hatchling, 12 pydantic, 13 pytest-cov-stub, 14 pytest-mock, 15 setuptools, 16 gitMinimal, 17 mercurial, 18}: 19 20buildPythonPackage rec { 21 pname = "versioningit"; 22 version = "3.3.0"; 23 pyproject = true; 24 25 src = fetchPypi { 26 inherit pname version; 27 hash = "sha256-uRrX1z5z0hIg5pVA8gIT8rcpofmzXATp4Tfq8o0iFNo="; 28 }; 29 30 build-system = [ hatchling ]; 31 32 dependencies = [ 33 packaging 34 ] 35 ++ lib.optionals (pythonOlder "3.11") [ tomli ]; 36 37 nativeCheckInputs = [ 38 coverage 39 pytestCheckHook 40 build 41 hatchling 42 pydantic 43 pytest-cov-stub 44 pytest-mock 45 setuptools 46 gitMinimal 47 mercurial 48 ]; 49 50 disabledTests = [ 51 # wants to write to the Nix store 52 "test_editable_mode" 53 # network access 54 "test_install_from_git_url" 55 "test_install_from_zip_url" 56 ]; 57 58 pythonImportsCheck = [ "versioningit" ]; 59 60 meta = with lib; { 61 description = "Setuptools plugin for determining package version from VCS"; 62 mainProgram = "versioningit"; 63 homepage = "https://github.com/jwodder/versioningit"; 64 changelog = "https://versioningit.readthedocs.io/en/latest/changelog.html"; 65 license = licenses.mit; 66 maintainers = with maintainers; [ DeeUnderscore ]; 67 }; 68}