1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitLab, 5 replaceVars, 6 graphviz, 7 setuptools, 8 markdown, 9}: 10 11buildPythonPackage rec { 12 pname = "mkdocs-graphviz"; 13 version = "1.5"; 14 pyproject = true; 15 16 src = fetchFromGitLab { 17 owner = "rod2ik"; 18 repo = "mkdocs-graphviz"; 19 tag = version; 20 hash = "sha256-5pc5RpOrDSONZcgIQMNsVxYwFyJ+PMcIt0GXDxCEyOg="; 21 }; 22 23 patches = [ 24 # Replace the path to the `graphviz` commands to use the one provided by Nixpkgs. 25 (replaceVars ./replace-path-to-dot.patch { 26 command = "\"${graphviz}/bin/\" + command"; 27 }) 28 ]; 29 30 build-system = [ setuptools ]; 31 32 dependencies = [ 33 markdown 34 ]; 35 36 pythonImportsCheck = [ "mkdocs_graphviz" ]; 37 38 # Tests are not available in the source code. 39 doCheck = false; 40 41 meta = { 42 description = "Configurable Python markdown extension for graphviz and Mkdocs"; 43 homepage = "https://gitlab.com/rod2ik/mkdocs-graphviz"; 44 license = lib.licenses.gpl3Only; 45 maintainers = with lib.maintainers; [ ]; 46 }; 47}