1{
2 lib,
3 buildPythonPackage,
4 cachecontrol,
5 feedparser,
6 fetchFromGitHub,
7 gitpython,
8 jsonfeed,
9 mkdocs,
10 pytestCheckHook,
11 pythonOlder,
12 setuptools,
13 validator-collection,
14}:
15
16buildPythonPackage rec {
17 pname = "mkdocs-rss-plugin";
18 version = "1.16.0";
19 pyproject = true;
20
21 disabled = pythonOlder "3.9";
22
23 src = fetchFromGitHub {
24 owner = "Guts";
25 repo = "mkdocs-rss-plugin";
26 rev = "refs/tags/${version}";
27 hash = "sha256-6FTOJQqK9lKYt6cVpKvMcNUrhSwX26032Vr4JyZ6sI8=";
28 };
29
30 postPatch = ''
31 sed -i "/--cov/d" setup.cfg
32 '';
33
34 build-system = [ setuptools ];
35
36 dependencies = [
37 cachecontrol
38 gitpython
39 mkdocs
40 ];
41
42 nativeCheckInputs = [
43 feedparser
44 jsonfeed
45 pytestCheckHook
46 validator-collection
47 ];
48
49 pythonImportsCheck = [ "mkdocs_rss_plugin" ];
50
51 disabledTests = [
52 # Tests require network access
53 "test_plugin_config_through_mkdocs"
54 "test_remote_image"
55 ];
56
57 disabledTestPaths = [
58 # Tests require network access
59 "tests/test_integrations_material_social_cards.py"
60 "tests/test_build_no_git.py"
61 "tests/test_build.py"
62 ];
63
64 meta = with lib; {
65 description = "MkDocs plugin to generate a RSS feeds for created and updated pages, using git log and YAML frontmatter";
66 homepage = "https://github.com/Guts/mkdocs-rss-plugin";
67 changelog = "https://github.com/Guts/mkdocs-rss-plugin/blob/${src.rev}/CHANGELOG.md";
68 license = licenses.mit;
69 maintainers = with maintainers; [ fab ];
70 };
71}