1{ lib
2, buildPythonPackage
3, fetchFromGitHub
4, pythonOlder
5, unittestCheckHook
6}:
7
8buildPythonPackage rec {
9 pname = "gitignore-parser";
10 version = "0.1.9";
11 format = "setuptools";
12
13 disabled = pythonOlder "3.7";
14
15 src = fetchFromGitHub {
16 owner = "mherrmann";
17 repo = "gitignore_parser";
18 rev = "refs/tags/v${version}";
19 hash = "sha256-T1XgcOHVFv/+oCEFKSoJeFAspJguimHasuREzjQwgWE=";
20 };
21
22 nativeCheckInputs = [
23 unittestCheckHook
24 ];
25
26 pythonImportsCheck = [
27 "gitignore_parser"
28 ];
29
30 meta = with lib; {
31 description = "A spec-compliant gitignore parser";
32 homepage = "https://github.com/mherrmann/gitignore_parser";
33 changelog = "https://github.com/mherrmann/gitignore_parser/releases/tag/v${version}";
34 license = licenses.mit;
35 maintainers = with maintainers; [ fab ];
36 };
37}