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