1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 cargo, 6 rustPlatform, 7 rustc, 8 setuptools, 9}: 10 11buildPythonPackage rec { 12 pname = "tree-sitter-make"; 13 version = "1.1.1"; 14 pyproject = true; 15 16 src = fetchFromGitHub { 17 owner = "tree-sitter-grammars"; 18 repo = "tree-sitter-make"; 19 rev = "v${version}"; 20 hash = "sha256-WiuhAp9JZKLd0wKCui9MV7AYFOW9dCbUp+kkVl1OEz0="; 21 }; 22 23 cargoDeps = rustPlatform.fetchCargoVendor { 24 inherit pname version src; 25 hash = "sha256-75jtur5rmG4zpNXSE3OpPVR+/lf4SICsh+kgzIKfbd4="; 26 }; 27 28 build-system = [ 29 cargo 30 rustPlatform.cargoSetupHook 31 rustc 32 setuptools 33 ]; 34 35 # There are no tests 36 doCheck = false; 37 pythonImportsCheck = [ 38 "tree_sitter_make" 39 ]; 40 41 meta = { 42 description = "Makefile grammar for tree-sitter"; 43 homepage = "https://github.com/tree-sitter-grammars/tree-sitter-make"; 44 license = lib.licenses.mit; 45 maintainers = with lib.maintainers; [ doronbehar ]; 46 }; 47}