1{ lib
2, buildPythonPackage
3, fetchFromGitHub
4, pythonOlder
5, jinja2
6, poetry-core
7}:
8
9buildPythonPackage rec {
10 pname = "jinja2-git";
11 version = "1.3.0";
12 pyproject = true;
13
14 disabled = pythonOlder "3.7";
15
16 src = fetchFromGitHub {
17 owner = "wemake-services";
18 repo = "jinja2-git";
19 rev = "refs/tags/${version}";
20 hash = "sha256-XuN2L3/HLcZ/WPWiCtufDOmkxj+q4I6IOgjrGQHfNLk=";
21 };
22
23 nativeBuildInputs = [ poetry-core ];
24
25 propagatedBuildInputs = [ jinja2 ];
26
27 # the tests need to be run on the git repository
28 doCheck = false;
29
30 pythonImportsCheck = [ "jinja2_git" ];
31
32 meta = with lib; {
33 homepage = "https://github.com/wemake-services/jinja2-git";
34 description = "Jinja2 extension to handle git-specific things";
35 changelog = "https://github.com/wemake-services/jinja2-git/blob/${src.rev}/CHANGELOG.md";
36 license = licenses.mit;
37 maintainers = with maintainers; [ cpcloud ];
38 };
39}