1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 hatchling, 6 pythonOlder, 7}: 8 9buildPythonPackage rec { 10 pname = "hatch-regex-commit"; 11 version = "0.0.3"; 12 pyproject = true; 13 14 disabled = pythonOlder "3.7"; 15 16 src = fetchFromGitHub { 17 owner = "frankie567"; 18 repo = "hatch-regex-commit"; 19 tag = "v${version}"; 20 hash = "sha256-E0DIBBaDmTCsZQ41NcjcbzgJ16BwhdexlrGWBdf77oA="; 21 }; 22 23 postPatch = '' 24 substituteInPlace pyproject.toml \ 25 --replace-fail 'dynamic = ["version"]' 'version = "${version}"' \ 26 --replace-fail ', "hatch-regex-commit"' "" \ 27 --replace-fail " --cov-report=term-missing --cov-config=pyproject.toml --cov=hatch_regex_commit --cov=tests" "" 28 ''; 29 30 build-system = [ hatchling ]; 31 32 dependencies = [ hatchling ]; 33 34 # Module has no tests 35 doCheck = false; 36 37 pythonImportsCheck = [ "hatch_regex_commit" ]; 38 39 meta = with lib; { 40 description = "Hatch plugin to create a commit and tag when bumping version"; 41 homepage = "https://github.com/frankie567/hatch-regex-commit"; 42 license = licenses.mit; 43 maintainers = with maintainers; [ fab ]; 44 }; 45}