1{ lib 2, buildPythonPackage 3, fetchgit 4, cmake 5}: 6 7buildPythonPackage rec { 8 pname = "editorconfig"; 9 version = "0.12.3"; 10 11 # fetchgit used to ensure test submodule is available 12 src = fetchgit { 13 url = "https://github.com/editorconfig/editorconfig-core-py"; 14 rev = "1a8fb62b9941fded9e4fb83a3d0599427f5484cb"; # Not tagged 15 sha256 = "0vx8rl7kii72965jsi01mdsz9rfi1q9bwy13x47iaqm6rmcwc1rb"; 16 }; 17 18 nativeBuildInputs = [ 19 cmake 20 ]; 21 22 dontUseCmakeConfigure = true; 23 24 checkPhase = '' 25 cmake . 26 # utf_8_char fails with Python 3 27 ctest -E "utf_8_char" . 28 ''; 29 30 pythonImportsCheck = [ "editorconfig" ]; 31 32 meta = with lib; { 33 description = "EditorConfig File Locator and Interpreter for Python"; 34 homepage = "https://editorconfig.org"; 35 license = licenses.psfl; 36 maintainers = with maintainers; [ ]; 37 }; 38}