1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 pytestCheckHook, 6 setuptools, 7 pythonOlder, 8}: 9 10buildPythonPackage rec { 11 pname = "whatthepatch"; 12 version = "1.0.7"; 13 pyproject = true; 14 15 disabled = pythonOlder "3.9"; 16 17 src = fetchFromGitHub { 18 owner = "cscorley"; 19 repo = "whatthepatch"; 20 tag = version; 21 hash = "sha256-0pkkwVo9yaFEZyitfpKMC8EVr8HgPLUkrGWmyYOdZNE="; 22 }; 23 24 build-system = [ setuptools ]; 25 26 nativeCheckInputs = [ pytestCheckHook ]; 27 28 pythonImportsCheck = [ "whatthepatch" ]; 29 30 meta = { 31 description = "Python library for both parsing and applying patch files"; 32 homepage = "https://github.com/cscorley/whatthepatch"; 33 changelog = "https://github.com/cscorley/whatthepatch/blob/${version}/HISTORY.md"; 34 license = lib.licenses.mit; 35 maintainers = with lib.maintainers; [ nickcao ]; 36 }; 37}