2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
fetchFromGitHub,
|
|
|
|
buildPythonPackage,
|
|
|
|
pythonOlder,
|
|
|
|
lark,
|
|
|
|
poetry-core,
|
|
|
|
pytestCheckHook,
|
2022-12-28 21:21:41 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "beancount-parser";
|
2024-05-15 15:35:15 +00:00
|
|
|
version = "1.2.3";
|
2023-01-11 07:51:40 +00:00
|
|
|
format = "pyproject";
|
2022-12-28 21:21:41 +00:00
|
|
|
|
|
|
|
disabled = pythonOlder "3.9";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "LaunchPlatform";
|
|
|
|
repo = "beancount-parser";
|
2023-01-11 07:51:40 +00:00
|
|
|
rev = "refs/tags/${version}";
|
2024-05-15 15:35:15 +00:00
|
|
|
hash = "sha256-8YcrsLdSRTixKXU/IM821kNcBo0jB/8DXA1/KiedsBY=";
|
2022-12-28 21:21:41 +00:00
|
|
|
};
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
buildInputs = [ poetry-core ];
|
2022-12-28 21:21:41 +00:00
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
propagatedBuildInputs = [ lark ];
|
2022-12-28 21:21:41 +00:00
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
nativeCheckInputs = [ pytestCheckHook ];
|
2022-12-28 21:21:41 +00:00
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
pythonImportsCheck = [ "beancount_parser" ];
|
2022-12-28 21:21:41 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Standalone Lark based Beancount syntax parser";
|
|
|
|
homepage = "https://github.com/LaunchPlatform/beancount-parser/";
|
2023-01-11 07:51:40 +00:00
|
|
|
changelog = "https://github.com/LaunchPlatform/beancount-parser/releases/tag/${version}";
|
2022-12-28 21:21:41 +00:00
|
|
|
license = with licenses; [ mit ];
|
|
|
|
maintainers = with maintainers; [ ambroisie ];
|
|
|
|
};
|
|
|
|
}
|