1{ 2 lib, 3 fetchFromGitHub, 4 buildPythonPackage, 5 pythonOlder, 6 beancount-parser, 7 click, 8 poetry-core, 9 pytestCheckHook, 10}: 11 12buildPythonPackage rec { 13 pname = "beancount-black"; 14 version = "1.0.5"; 15 16 disabled = pythonOlder "3.9"; 17 format = "pyproject"; 18 19 src = fetchFromGitHub { 20 owner = "LaunchPlatform"; 21 repo = "beancount-black"; 22 tag = version; 23 hash = "sha256-vo11mlgDhyc8YFnULJ4AFrANWmGpAMNX5jJ6QaUNqk0="; 24 }; 25 26 buildInputs = [ poetry-core ]; 27 28 propagatedBuildInputs = [ 29 beancount-parser 30 click 31 ]; 32 33 nativeCheckInputs = [ pytestCheckHook ]; 34 35 pythonImportsCheck = [ "beancount_black" ]; 36 37 meta = with lib; { 38 description = "Opinioned code formatter for Beancount"; 39 mainProgram = "bean-black"; 40 homepage = "https://github.com/LaunchPlatform/beancount-black/"; 41 license = with licenses; [ mit ]; 42 maintainers = with maintainers; [ ambroisie ]; 43 }; 44}