summaryrefslogtreecommitdiff
path: root/pkgs/development/python-modules/beancount-parser/default.nix
blob: 6a6d12e6b9a3f6b603055596a549acc9c25f65d8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
{
  lib,
  fetchFromGitHub,
  buildPythonPackage,
  lark,
  poetry-core,
  pytestCheckHook,
}:

buildPythonPackage (finalAttrs: {
  pname = "beancount-parser";
  version = "1.2.3";
  pyproject = true;

  src = fetchFromGitHub {
    owner = "LaunchPlatform";
    repo = "beancount-parser";
    tag = finalAttrs.version;
    hash = "sha256-8YcrsLdSRTixKXU/IM821kNcBo0jB/8DXA1/KiedsBY=";
  };

  buildInputs = [ poetry-core ];

  propagatedBuildInputs = [ lark ];

  nativeCheckInputs = [ pytestCheckHook ];

  pythonImportsCheck = [ "beancount_parser" ];

  meta = {
    description = "Standalone Lark based Beancount syntax parser";
    homepage = "https://github.com/LaunchPlatform/beancount-parser/";
    changelog = "https://github.com/LaunchPlatform/beancount-parser/releases/tag/${finalAttrs.version}";
    license = with lib.licenses; [ mit ];
    maintainers = with lib.maintainers; [ ambroisie ];
  };
})