mkdocstrings-github 0.4.5__tar.gz → 0.5.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (110) hide show
  1. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/.github/CONTRIBUTING.md +15 -4
  2. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/PKG-INFO +24 -4
  3. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/README.md +23 -3
  4. mkdocstrings_github-0.5.1/action.yaml +114 -0
  5. mkdocstrings_github-0.5.1/docs/changelog.md +227 -0
  6. mkdocstrings_github-0.5.1/docs/img/example_dark.png +0 -0
  7. mkdocstrings_github-0.5.1/docs/img/example_light.png +0 -0
  8. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/docs/index.md +7 -1
  9. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/docs/usage/index.md +0 -3
  10. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/docs/usage/signatures.md +22 -0
  11. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/mkdocs.yml +2 -3
  12. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/pyproject.toml +1 -1
  13. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/src/mkdocstrings_handlers/github/config.py +9 -11
  14. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/src/mkdocstrings_handlers/github/handler.py +29 -32
  15. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/src/mkdocstrings_handlers/github/objects.py +62 -29
  16. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/src/mkdocstrings_handlers/github/templates/material/action.html.jinja +1 -1
  17. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/src/mkdocstrings_handlers/github/templates/material/workflow.html.jinja +7 -1
  18. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/helpers.py +3 -1
  19. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/__init__.py +15 -0
  20. mkdocstrings_github-0.5.1/test/snapshots/external/8bacb89d75273f2bfee27f0d86fd49def327fd3e33ba7595aac8058ab214181d.html +38 -0
  21. mkdocstrings_github-0.5.1/test/snapshots/external/9cc6f18114bfd48128d8cc74d40d4f19911408af280ba1866f07209ae80d5e42.html +52 -0
  22. mkdocstrings_github-0.5.1/test/snapshots/external/b6163f7b64f009d0f8992a0ccb4da0af6b02b5411dceb42cb0816b5721ebade0.html +42 -0
  23. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/test_handler.py +2 -2
  24. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/test_render_workflow.py +21 -0
  25. mkdocstrings_github-0.4.5/action.yaml +0 -38
  26. mkdocstrings_github-0.4.5/docs/changelog.md +0 -1
  27. mkdocstrings_github-0.4.5/logo.png +0 -0
  28. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/.github/CODEOWNERS +0 -0
  29. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/.github/FUNDING.yml +0 -0
  30. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/.github/renovate.json5 +0 -0
  31. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/.github/workflows/docs.yaml +0 -0
  32. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/.github/workflows/example_workflow.yml +0 -0
  33. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/.github/workflows/qualify.yaml +0 -0
  34. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/.github/workflows/release.yaml +0 -0
  35. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/.gitignore +0 -0
  36. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/.gitmodules +0 -0
  37. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/.pre-commit-config.yaml +0 -0
  38. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/LICENSE +0 -0
  39. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/docs/contributing.md +0 -0
  40. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/docs/credits.md +0 -0
  41. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/docs/favicon.png +0 -0
  42. {mkdocstrings_github-0.4.5/docs → mkdocstrings_github-0.5.1/docs/img}/logo.png +0 -0
  43. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/docs/license-page.md +0 -0
  44. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/docs/overrides/main.html +0 -0
  45. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/docs/overrides/partials/toc-item.html +0 -0
  46. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/docs/stylesheets/extra.css +0 -0
  47. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/docs/usage/general.md +0 -0
  48. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/docs/usage/headings.md +0 -0
  49. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/docs/usage/parameters.md +0 -0
  50. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/src/mkdocstrings_handlers/github/__init__.py +0 -0
  51. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/src/mkdocstrings_handlers/github/py.typed +0 -0
  52. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/src/mkdocstrings_handlers/github/rendering.py +0 -0
  53. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/src/mkdocstrings_handlers/github/templates/material/heading.html.jinja +0 -0
  54. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/src/mkdocstrings_handlers/github/templates/material/inputs.html.jinja +0 -0
  55. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/src/mkdocstrings_handlers/github/templates/material/outputs.html.jinja +0 -0
  56. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/src/mkdocstrings_handlers/github/templates/material/secrets.html.jinja +0 -0
  57. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/src/mkdocstrings_handlers/github/templates/material/style.css +0 -0
  58. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/__init__.py +0 -0
  59. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/conftest.py +0 -0
  60. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/docs/.gitkeep +0 -0
  61. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/.gitignore +0 -0
  62. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/06f909d26ca3c2008ca57aeae14dc63fb04ade05997b8aed6ae1573bf42b5841.html +0 -0
  63. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/0a37a4286738a72a224871dbd1bcd3c662e768f800a8e2b92c410d672c1d19fc.html +0 -0
  64. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/0ef4f0725dafdff18802cd0dd8839c35562755c90458f0dd3ef7743e87efdd89.html +0 -0
  65. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/1322d6390dbc167e4d2734b6ff7ac30265a52feb242ece864fd08dd36a88214a.html +0 -0
  66. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/22929d6c2b70b481583d7b07fd7bff72dba985a465d42ad4ee5a7f557429102f.html +0 -0
  67. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/23cc1367f9dd06c1d51e4b1c8a5a2ea807f32a78de9c061438f4d2315bcc3d0e.html +0 -0
  68. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/24dfcb59a486346316de8203f742d4f3dd9129f9a57252c37741ad27d0eaddd7.html +0 -0
  69. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/2500c66e16468b20050dd9b8b152a48644d008c0316e444f47afc7bc5117e004.html +0 -0
  70. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/27b0437dc257c9970044eb25da334453829a4ae0450e98cf7a965aff5ad7fcba.html +0 -0
  71. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/28df0ab9fe5662687b72cbb8b2c8e2e18b98beb5a114a505ad845c91b8955a2e.html +0 -0
  72. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/293f8ca976970a4fb9549b1bd3b6f6be8a13bd86d9c34bb98813def62a5777aa.html +0 -0
  73. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/2eb63f18b2d0aaf8000ffcc081c80067937fc7cacea496c2871198aa3bc12a14.html +0 -0
  74. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/36d5597971381260ce0cd98b6ba1c3973134add32288bf34f47290fdbe55b0ec.html +0 -0
  75. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/3cb099624d882a4cde3ef6fdbea56c9aced9331dca1e19c7bc311c2611782e0d.html +0 -0
  76. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/459e6df9404add89f3e159d2b0fdfc81e7f0545da8efaa690de8c06aebd1d2bf.html +0 -0
  77. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/50af1499553795c8cd859a1c9aa5ba162ef1c3dd9fa466668fc2da5bb002a61c.html +0 -0
  78. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/572198cee6d40e3c875970ee6b4c654b3edae54c5a00ee4792df2b0d5a161796.html +0 -0
  79. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/5a2f11e94bc00c7a5122364dcffcdc9bd5c514a773fbf4d1b04fa7e96ba2cfa5.html +0 -0
  80. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/5a75c7bf0d0c9f0d6e193263fe59288ec69ef2d93ec6f8bab8e240b2b58b3dd3.html +0 -0
  81. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/5f0693318b13614e630f852af6ad9165a3793e2e011d4de786b84e178eb411bc.html +0 -0
  82. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/6d20fba34c55a0c3c25d29a29470de573812305d70dabac3104a7d18d92b2b86.html +0 -0
  83. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/757b79d7975f29e7b7eeda8c910578cb858a867dc4c647c4b5bc9a4c45dbf62e.html +0 -0
  84. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/78f74a133e98bd757a1bd1c4667dc3a5d7cc40cc78daf596187999cb083ec6c4.html +0 -0
  85. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/78feb92e4171bf067dd1615523e5c9cac0de998bb7102ee70da2e145d1262339.html +0 -0
  86. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/84f918940f7b729b21a97d971a27bf994b2deb8ee5d9909481d98f702dfec96a.html +0 -0
  87. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/856a4ff20ee15b09367d852d57cdb6a3376b799760365dbf7677c216156a7b4d.html +0 -0
  88. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/93bf082d40ca4b6730a503aa4d265901a8cfed7ed1a6e9bb6e584c2c3ebd18af.html +0 -0
  89. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/94b8c0c6610d32e8a877cb18b47ff8b072203c6a1e8fddc67be1d7e5b963c385.html +0 -0
  90. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/98e4b6474a6f67576ae40a75e152e6bd8c3e743259ad7f1d08890def2ff858d1.html +0 -0
  91. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/98ed5c777c164326632ca657e3cb87ae3f9b75bf9793ab2db4ab90ee7874621c.html +0 -0
  92. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/ac47b3b933709154de762d06903d78925cea9f1ec93865386d669680cf17e4a8.html +0 -0
  93. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/ace14d7e4e53515a281c109aca1d7b5bccb1259ff0c3e0c28a8e09908e4f2f26.html +0 -0
  94. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/b972a05ffc5672d471d5b1e84b01470a3363a25f9d9adbc8d82f4b9fd21a94a1.html +0 -0
  95. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/bbea0ecf08aec9444ed75cbffd5424aa19e285ac64a53d1bb50f6130230b3c97.html +0 -0
  96. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/c2181f9e06dd6b7437f14e815c4fd32ec304e4474c93e86c02b43f41367a79ff.html +0 -0
  97. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/c3d75cc820623b26630624895fbc53ff7ea764ede141a2751387fca0bddb0c42.html +0 -0
  98. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/c50b7f91aafff5caf0fe0ff96a922b499617966705cde0d3622191f51f523b38.html +0 -0
  99. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/c8c895c400f0532aa3afe641f79ed14bc399b504169242c0a9f77572c185def2.html +0 -0
  100. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/cdad9a8909ec6448ff4392f523d4c7d41dcba61fc635e7e744026f901df04913.html +0 -0
  101. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/d0d656ae32436d7b190665f98f3fe2d7a6250ee7ff4e1fb1bcd9a1364d3da2cb.html +0 -0
  102. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/dbb6b804e35c3cf48b6ea556486a82cf6f34af4d7cc455bfc02995969f45d09f.html +0 -0
  103. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/de1ce14a6155d8b1e4185e0eed7490872ef3af13b459ce5430ee5fc070f549d5.html +0 -0
  104. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/df4a79ccbc4e4aa4c1a3135f1b42ce67cbebdf65acec195630d961605206c078.html +0 -0
  105. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/e567efbdae19280c4c56a70a27de39e0efdc422d99c9d497629128fd3ec553d5.html +0 -0
  106. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/f0d6c0adbfcc02896663bc47e38910252279cabfe89c8c196c23f02b7d65d77d.html +0 -0
  107. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/f575eacc0b72560cfc4e759f838f4ba8fc6ad1ee88d56fa707a1a840baf3e679.html +0 -0
  108. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/f64c666c9ace98f632d96aea732c4da55112d9c496baef00eb997c68c2c09264.html +0 -0
  109. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/snapshots/external/f90542b4e3cbaf7e9820cdad6bbe707e3210983c911f11584cfae580e5cf6a04.html +0 -0
  110. {mkdocstrings_github-0.4.5 → mkdocstrings_github-0.5.1}/test/test_render_action.py +0 -0
@@ -2,7 +2,18 @@
2
2
 
3
3
  Thank you for considering contributing! Please follow these steps to get started:
4
4
 
5
- ## 1. Environment Setup
5
+ ## 1. Clone repository
6
+
7
+ Clone the repository and setup its submodules. The [watermarkhu/mkdocstrings-github-fixture](https://github.com/watermarkhu/mkdocstrings-github-fixture) repository is used as a fixture repository.
8
+
9
+ ```sh
10
+ git clone https://github.com/watermarkhu/mkdocstrings-github
11
+ cd mkdocstrings-github
12
+ git submodule init
13
+ git submodule update
14
+ ```
15
+
16
+ ## 2. Environment Setup
6
17
 
7
18
  Install all dependencies using [uv](https://github.com/astral-sh/uv):
8
19
 
@@ -12,7 +23,7 @@ uv sync --all-groups
12
23
 
13
24
  Learn more about uv: [uv documentation](https://github.com/astral-sh/uv)
14
25
 
15
- ## 2. Pre-commit Hooks using prek
26
+ ## 3. Pre-commit Hooks using prek
16
27
 
17
28
  Set up [prek](https://github.com/j178/prek) hooks to ensure code quality:
18
29
 
@@ -22,7 +33,7 @@ uv run prek install
22
33
 
23
34
  See: [prek documentation](https://prek.j178.dev/)
24
35
 
25
- ## 3. Running Tests
36
+ ## 4. Running Tests
26
37
 
27
38
  Run tests with [pytest](https://docs.pytest.org/en/stable/):
28
39
 
@@ -32,7 +43,7 @@ uv run pytest
32
43
 
33
44
  See: [pytest documentation](https://docs.pytest.org/en/stable/)
34
45
 
35
- ## 4. Pull Request Guidelines
46
+ ## 5. Pull Request Guidelines
36
47
 
37
48
  - Pull requests should target the `main` branch.
38
49
  - Use [Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0/) for commit messages.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: mkdocstrings-github
3
- Version: 0.4.5
3
+ Version: 0.5.1
4
4
  Summary: A GitHub Action handler for mkdocstrings
5
5
  Author-email: Mark Hu <watermarkhu@gmail.com>
6
6
  License: MIT
@@ -33,14 +33,26 @@ Description-Content-Type: text/markdown
33
33
 
34
34
  <p align="center">A GitHub Actions handler for <a href="https://github.com/mkdocstrings/mkdocstrings"><i>mkdocstrings</i></a>.</p>
35
35
 
36
- <p align="center"><img width=300px src="logo.png"></p>
36
+ <!-- --8<-- [end:header] -->
37
+
38
+ <p align="center"><img width=300px src="docs/img/logo.png"></p>
37
39
 
38
40
  [![Qualify](https://github.com/watermarkhu/mkdocstrings-github/actions/workflows/qualify.yaml/badge.svg?branch=main)](https://github.com/watermarkhu/mkdocstrings-github/actions/workflows/qualify.yaml)
39
41
  [![documentation](https://img.shields.io/badge/docs-mkdocs-708FCC.svg?style=flat)](https://watermarkhu.nl/mkdocstrings-github)
40
42
  [![pypi version](https://img.shields.io/pypi/v/mkdocstrings-github.svg)](https://pypi.org/project/mkdocstrings-github/)
41
43
  [![codecov](https://codecov.io/github/watermarkhu/mkdocstrings-github/graph/badge.svg?token=M6XW8UeURE)](https://codecov.io/github/watermarkhu/mkdocstrings-github)
42
44
 
43
- <!-- --8<-- [end:header] -->
45
+
46
+
47
+ For example, the following page is generated from [actions/checkout](https://github.com/actions/checkout):
48
+
49
+ <picture>
50
+ <source media="(prefers-color-scheme: dark)" srcset="docs/img/example_dark.png">
51
+ <source media="(prefers-color-scheme: light)" srcset="docs/img/example_light.png">
52
+ <img alt="Fallback image description" src="docs/img/example_light.png">
53
+ </picture>
54
+
55
+
44
56
  <!-- --8<-- [start:install] -->
45
57
  You can install the GitHub handler by specifying it as a dependency:
46
58
 
@@ -49,9 +61,17 @@ You can install the GitHub handler by specifying it as a dependency:
49
61
  # adapt to your dependencies manager
50
62
  [project]
51
63
  dependencies = [
52
- "mkdocstrings-github>=0.X.Y",
64
+ "mkdocstrings-github",
53
65
  ]
54
66
  ```
67
+
68
+ after which the generated documentation can be inserted in the markdown page with:
69
+
70
+ ```md
71
+ ::: <path-to-action-or-workflow>
72
+ handler: github
73
+ ```
74
+
55
75
  <!-- --8<-- [end:install] -->
56
76
 
57
77
  <!-- --8<-- [start:footer] -->
@@ -4,14 +4,26 @@
4
4
 
5
5
  <p align="center">A GitHub Actions handler for <a href="https://github.com/mkdocstrings/mkdocstrings"><i>mkdocstrings</i></a>.</p>
6
6
 
7
- <p align="center"><img width=300px src="logo.png"></p>
7
+ <!-- --8<-- [end:header] -->
8
+
9
+ <p align="center"><img width=300px src="docs/img/logo.png"></p>
8
10
 
9
11
  [![Qualify](https://github.com/watermarkhu/mkdocstrings-github/actions/workflows/qualify.yaml/badge.svg?branch=main)](https://github.com/watermarkhu/mkdocstrings-github/actions/workflows/qualify.yaml)
10
12
  [![documentation](https://img.shields.io/badge/docs-mkdocs-708FCC.svg?style=flat)](https://watermarkhu.nl/mkdocstrings-github)
11
13
  [![pypi version](https://img.shields.io/pypi/v/mkdocstrings-github.svg)](https://pypi.org/project/mkdocstrings-github/)
12
14
  [![codecov](https://codecov.io/github/watermarkhu/mkdocstrings-github/graph/badge.svg?token=M6XW8UeURE)](https://codecov.io/github/watermarkhu/mkdocstrings-github)
13
15
 
14
- <!-- --8<-- [end:header] -->
16
+
17
+
18
+ For example, the following page is generated from [actions/checkout](https://github.com/actions/checkout):
19
+
20
+ <picture>
21
+ <source media="(prefers-color-scheme: dark)" srcset="docs/img/example_dark.png">
22
+ <source media="(prefers-color-scheme: light)" srcset="docs/img/example_light.png">
23
+ <img alt="Fallback image description" src="docs/img/example_light.png">
24
+ </picture>
25
+
26
+
15
27
  <!-- --8<-- [start:install] -->
16
28
  You can install the GitHub handler by specifying it as a dependency:
17
29
 
@@ -20,9 +32,17 @@ You can install the GitHub handler by specifying it as a dependency:
20
32
  # adapt to your dependencies manager
21
33
  [project]
22
34
  dependencies = [
23
- "mkdocstrings-github>=0.X.Y",
35
+ "mkdocstrings-github",
24
36
  ]
25
37
  ```
38
+
39
+ after which the generated documentation can be inserted in the markdown page with:
40
+
41
+ ```md
42
+ ::: <path-to-action-or-workflow>
43
+ handler: github
44
+ ```
45
+
26
46
  <!-- --8<-- [end:install] -->
27
47
 
28
48
  <!-- --8<-- [start:footer] -->
@@ -0,0 +1,114 @@
1
+ name: 'Checkout'
2
+ description: 'Checkout a Git repository at a particular version'
3
+
4
+ branding:
5
+ icon: 'github'
6
+ color: 'blue'
7
+
8
+ inputs:
9
+ repository:
10
+ description: 'Repository name with owner. For example, actions/checkout'
11
+ default: ${{ github.repository }}
12
+ ref:
13
+ description: >
14
+ The branch, tag or SHA to checkout. When checking out the repository that
15
+ triggered a workflow, this defaults to the reference or SHA for that
16
+ event. Otherwise, uses the default branch.
17
+ token:
18
+ description: >
19
+ Personal access token (PAT) used to fetch the repository. The PAT is configured
20
+ with the local git config, which enables your scripts to run authenticated git
21
+ commands. The post-job step removes the PAT.
22
+
23
+
24
+ We recommend using a service account with the least permissions necessary.
25
+ Also when generating a new PAT, select the least scopes necessary.
26
+
27
+
28
+ [Learn more about creating and using encrypted secrets](https://help.github.com/en/actions/automating-your-workflow-with-github-actions/creating-and-using-encrypted-secrets)
29
+ default: ${{ github.token }}
30
+ ssh-key:
31
+ description: >
32
+ SSH key used to fetch the repository. The SSH key is configured with the local
33
+ git config, which enables your scripts to run authenticated git commands.
34
+ The post-job step removes the SSH key.
35
+
36
+
37
+ We recommend using a service account with the least permissions necessary.
38
+
39
+
40
+ [Learn more about creating and using
41
+ encrypted secrets](https://help.github.com/en/actions/automating-your-workflow-with-github-actions/creating-and-using-encrypted-secrets)
42
+ ssh-known-hosts:
43
+ description: >
44
+ Known hosts in addition to the user and global host key database. The public
45
+ SSH keys for a host may be obtained using the utility `ssh-keyscan`. For example,
46
+ `ssh-keyscan github.com`. The public key for github.com is always implicitly added.
47
+ ssh-strict:
48
+ description: >
49
+ Whether to perform strict host key checking. When true, adds the options `StrictHostKeyChecking=yes`
50
+ and `CheckHostIP=no` to the SSH command line. Use the input `ssh-known-hosts` to
51
+ configure additional hosts.
52
+ default: true
53
+ ssh-user:
54
+ description: >
55
+ The user to use when connecting to the remote SSH host. By default 'git' is used.
56
+ default: git
57
+ persist-credentials:
58
+ description: 'Whether to configure the token or SSH key with the local git config'
59
+ default: true
60
+ path:
61
+ description: 'Relative path under $GITHUB_WORKSPACE to place the repository'
62
+ clean:
63
+ description: 'Whether to execute `git clean -ffdx && git reset --hard HEAD` before fetching'
64
+ default: true
65
+ filter:
66
+ description: >
67
+ Partially clone against a given filter.
68
+ Overrides sparse-checkout if set.
69
+ default: null
70
+ sparse-checkout:
71
+ description: >
72
+ Do a sparse checkout on given patterns.
73
+ Each pattern should be separated with new lines.
74
+ default: null
75
+ sparse-checkout-cone-mode:
76
+ description: >
77
+ Specifies whether to use cone-mode when doing a sparse checkout.
78
+ default: true
79
+ fetch-depth:
80
+ description: 'Number of commits to fetch. 0 indicates all history for all branches and tags.'
81
+ default: 1
82
+ fetch-tags:
83
+ description: 'Whether to fetch tags, even if fetch-depth > 0.'
84
+ default: false
85
+ show-progress:
86
+ description: 'Whether to show progress status output when fetching.'
87
+ default: true
88
+ lfs:
89
+ description: 'Whether to download Git-LFS files'
90
+ default: false
91
+ submodules:
92
+ description: >
93
+ Whether to checkout submodules: `true` to checkout submodules or `recursive` to
94
+ recursively checkout submodules.
95
+
96
+
97
+ When the `ssh-key` input is not provided, SSH URLs beginning with `git@github.com:` are
98
+ converted to HTTPS.
99
+ default: false
100
+ set-safe-directory:
101
+ description: Add repository path as safe.directory for Git global config by running `git config --global --add safe.directory <path>`
102
+ default: true
103
+ github-server-url:
104
+ description: The base URL for the GitHub instance that you are trying to clone from, will use environment defaults to fetch from the same instance that the workflow is running from unless specified. Example URLs are https://github.com or https://my-ghes-server.example.com
105
+ required: false
106
+ outputs:
107
+ ref:
108
+ description: 'The branch, tag or SHA that was checked out'
109
+ commit:
110
+ description: 'The commit SHA that was checked out'
111
+ runs:
112
+ using: node24
113
+ main: dist/index.js
114
+ post: dist/index.js
@@ -0,0 +1,227 @@
1
+ # CHANGELOG
2
+
3
+ <!-- version list -->
4
+
5
+ ## v0.5.1 (2025-10-14)
6
+
7
+ ### Bug Fixes
8
+
9
+ - Do not validate signature_repository
10
+ ([#34](https://github.com/watermarkhu/mkdocstrings-github/pull/34),
11
+ [`3ead525`](https://github.com/watermarkhu/mkdocstrings-github/commit/3ead5253eb68e9a5fb5def55e807801afc1ef106))
12
+
13
+
14
+ ## v0.5.0 (2025-10-13)
15
+
16
+ ### Bug Fixes
17
+
18
+ - Properly show read-all/write-all permissions
19
+ ([#33](https://github.com/watermarkhu/mkdocstrings-github/pull/33),
20
+ [`5f5e792`](https://github.com/watermarkhu/mkdocstrings-github/commit/5f5e7921fd326bbcdec903101107c6128dab5dbf))
21
+
22
+ ### Documentation
23
+
24
+ - Better docs with actions/checkout example
25
+ ([#33](https://github.com/watermarkhu/mkdocstrings-github/pull/33),
26
+ [`5f5e792`](https://github.com/watermarkhu/mkdocstrings-github/commit/5f5e7921fd326bbcdec903101107c6128dab5dbf))
27
+
28
+ ### Features
29
+
30
+ - Move signature repository name to local options
31
+ ([#33](https://github.com/watermarkhu/mkdocstrings-github/pull/33),
32
+ [`5f5e792`](https://github.com/watermarkhu/mkdocstrings-github/commit/5f5e7921fd326bbcdec903101107c6128dab5dbf))
33
+
34
+
35
+ ## v0.4.5 (2025-10-13)
36
+
37
+ ### Refactoring
38
+
39
+ - Show annotation in stead of empty
40
+ ([#32](https://github.com/watermarkhu/mkdocstrings-github/pull/32),
41
+ [`46942af`](https://github.com/watermarkhu/mkdocstrings-github/commit/46942af6c6c2794830738749909edd39ea2ca204))
42
+
43
+ - Show annotation instead of empty
44
+ ([#32](https://github.com/watermarkhu/mkdocstrings-github/pull/32),
45
+ [`46942af`](https://github.com/watermarkhu/mkdocstrings-github/commit/46942af6c6c2794830738749909edd39ea2ca204))
46
+
47
+
48
+ ## v0.4.4 (2025-10-13)
49
+
50
+ ### Bug Fixes
51
+
52
+ - **templates**: Hide signature sections properly
53
+ ([#31](https://github.com/watermarkhu/mkdocstrings-github/pull/31),
54
+ [`86d9628`](https://github.com/watermarkhu/mkdocstrings-github/commit/86d9628770ab235280ffc65434009355946b7d0c))
55
+
56
+
57
+ ## v0.4.3 (2025-10-12)
58
+
59
+ ### Bug Fixes
60
+
61
+ - Hide secrets and inputs from signature if there are none
62
+ ([#30](https://github.com/watermarkhu/mkdocstrings-github/pull/30),
63
+ [`f9831f6`](https://github.com/watermarkhu/mkdocstrings-github/commit/f9831f648b8eeed287f35843a1d15c7f845c1bb0))
64
+
65
+ ### Continuous Integration
66
+
67
+ - More tests ([#30](https://github.com/watermarkhu/mkdocstrings-github/pull/30),
68
+ [`f9831f6`](https://github.com/watermarkhu/mkdocstrings-github/commit/f9831f648b8eeed287f35843a1d15c7f845c1bb0))
69
+
70
+ ### Performance Improvements
71
+
72
+ - Use GITHUB_REPOSITORY env var in GitHub Actions
73
+ ([#30](https://github.com/watermarkhu/mkdocstrings-github/pull/30),
74
+ [`f9831f6`](https://github.com/watermarkhu/mkdocstrings-github/commit/f9831f648b8eeed287f35843a1d15c7f845c1bb0))
75
+
76
+
77
+ ## v0.4.2 (2025-10-08)
78
+
79
+ ### Bug Fixes
80
+
81
+ - Better package tag ordering ([#28](https://github.com/watermarkhu/mkdocstrings-github/pull/28),
82
+ [`10dc87a`](https://github.com/watermarkhu/mkdocstrings-github/commit/10dc87a001908af6522320a5248ce4c988e441a3))
83
+
84
+
85
+ ## v0.4.1 (2025-10-08)
86
+
87
+ ### Bug Fixes
88
+
89
+ - Tag ordering ([#27](https://github.com/watermarkhu/mkdocstrings-github/pull/27),
90
+ [`76256f5`](https://github.com/watermarkhu/mkdocstrings-github/commit/76256f52bbd53be825ba0a0576d7cb6a6da54d3a))
91
+
92
+ ### Documentation
93
+
94
+ - Update docs ([#26](https://github.com/watermarkhu/mkdocstrings-github/pull/26),
95
+ [`96f650f`](https://github.com/watermarkhu/mkdocstrings-github/commit/96f650f1d4af5b5d6da4704e7b2184e4016f3a39))
96
+
97
+
98
+ ## v0.4.0 (2025-10-08)
99
+
100
+ ### Continuous Integration
101
+
102
+ - **deps**: Update actions/checkout action to v5
103
+ ([#22](https://github.com/watermarkhu/mkdocstrings-github/pull/22),
104
+ [`fc56971`](https://github.com/watermarkhu/mkdocstrings-github/commit/fc569719b4387f11119de588d2f67f1daa09c233))
105
+
106
+ - **deps**: Update astral-sh/setup-uv action to v7
107
+ ([#24](https://github.com/watermarkhu/mkdocstrings-github/pull/24),
108
+ [`a07de53`](https://github.com/watermarkhu/mkdocstrings-github/commit/a07de53b318859a365215730c2c09d0d5fdcf5b1))
109
+
110
+ ### Features
111
+
112
+ - Get releases using tags ([#25](https://github.com/watermarkhu/mkdocstrings-github/pull/25),
113
+ [`25ea11d`](https://github.com/watermarkhu/mkdocstrings-github/commit/25ea11d8c0f92a1e49f8b35b60456259e4e0ec7b))
114
+
115
+
116
+ ## v0.3.0 (2025-10-07)
117
+
118
+ ### Bug Fixes
119
+
120
+ - Prek configuration with local uv
121
+ ([#20](https://github.com/watermarkhu/mkdocstrings-github/pull/20),
122
+ [`0d53c40`](https://github.com/watermarkhu/mkdocstrings-github/commit/0d53c4029fc0f2e30f4f223b6d81221236254832))
123
+
124
+ ### Build System
125
+
126
+ - **deps**: Update dependency ruff to ~=0.14.0
127
+ ([#21](https://github.com/watermarkhu/mkdocstrings-github/pull/21),
128
+ [`f87cf24`](https://github.com/watermarkhu/mkdocstrings-github/commit/f87cf2485121f4056279ce06ed721e02fc475f1b))
129
+
130
+ ### Continuous Integration
131
+
132
+ - Add codecov ([#20](https://github.com/watermarkhu/mkdocstrings-github/pull/20),
133
+ [`0d53c40`](https://github.com/watermarkhu/mkdocstrings-github/commit/0d53c4029fc0f2e30f4f223b6d81221236254832))
134
+
135
+ - **deps**: Update peter-evans/create-or-update-comment action to v5
136
+ ([#19](https://github.com/watermarkhu/mkdocstrings-github/pull/19),
137
+ [`8135a2b`](https://github.com/watermarkhu/mkdocstrings-github/commit/8135a2bff69a41bde0676b991145ff089563bf7b))
138
+
139
+ ### Features
140
+
141
+ - Hide default and section if non are available
142
+ ([#20](https://github.com/watermarkhu/mkdocstrings-github/pull/20),
143
+ [`0d53c40`](https://github.com/watermarkhu/mkdocstrings-github/commit/0d53c4029fc0f2e30f4f223b6d81221236254832))
144
+
145
+ - Hide default and section if non are available.
146
+ ([#20](https://github.com/watermarkhu/mkdocstrings-github/pull/20),
147
+ [`0d53c40`](https://github.com/watermarkhu/mkdocstrings-github/commit/0d53c4029fc0f2e30f4f223b6d81221236254832))
148
+
149
+
150
+ ## v0.2.6 (2025-10-02)
151
+
152
+ ### Bug Fixes
153
+
154
+ - Empty workflow_call ([#18](https://github.com/watermarkhu/mkdocstrings-github/pull/18),
155
+ [`368b9b5`](https://github.com/watermarkhu/mkdocstrings-github/commit/368b9b5097d6d0c061cb9addbfc9fc721a16dea7))
156
+
157
+ ### Continuous Integration
158
+
159
+ - **deps**: Update peter-evans/find-comment action to v4
160
+ ([#17](https://github.com/watermarkhu/mkdocstrings-github/pull/17),
161
+ [`8e2375d`](https://github.com/watermarkhu/mkdocstrings-github/commit/8e2375d1df0a9883c9a365dfc5b2563997fb1f70))
162
+
163
+
164
+ ## v0.2.5 (2025-09-29)
165
+
166
+ ### Bug Fixes
167
+
168
+ - No repo set ([#16](https://github.com/watermarkhu/mkdocstrings-github/pull/16),
169
+ [`554d230`](https://github.com/watermarkhu/mkdocstrings-github/commit/554d230a3c8da0bee86a2c8b2805c873852d6bfd))
170
+
171
+ ### Documentation
172
+
173
+ - Small fix ([#15](https://github.com/watermarkhu/mkdocstrings-github/pull/15),
174
+ [`22c6693`](https://github.com/watermarkhu/mkdocstrings-github/commit/22c669395cce94b315ab08434fdc4e7ba167f7a5))
175
+
176
+
177
+ ## v0.2.4 (2025-09-29)
178
+
179
+ ### Bug Fixes
180
+
181
+ - Allow setting hostname ([#14](https://github.com/watermarkhu/mkdocstrings-github/pull/14),
182
+ [`4676e57`](https://github.com/watermarkhu/mkdocstrings-github/commit/4676e57cda03b8a52ae6facf4a28f3dde9adb365))
183
+
184
+ - Set hostname ([#14](https://github.com/watermarkhu/mkdocstrings-github/pull/14),
185
+ [`4676e57`](https://github.com/watermarkhu/mkdocstrings-github/commit/4676e57cda03b8a52ae6facf4a28f3dde9adb365))
186
+
187
+
188
+ ## v0.2.3 (2025-09-29)
189
+
190
+ ### Bug Fixes
191
+
192
+ - Default host ([#13](https://github.com/watermarkhu/mkdocstrings-github/pull/13),
193
+ [`8ac9b06`](https://github.com/watermarkhu/mkdocstrings-github/commit/8ac9b062e53b47e27cc1adad6c206087d8a7da1a))
194
+
195
+
196
+ ## v0.2.2 (2025-09-29)
197
+
198
+ ### Bug Fixes
199
+
200
+ - Get GH_TOKEN ([#12](https://github.com/watermarkhu/mkdocstrings-github/pull/12),
201
+ [`3c449ea`](https://github.com/watermarkhu/mkdocstrings-github/commit/3c449ea0bfeaac96667d7d31b668d25921279bd6))
202
+
203
+
204
+ ## v0.2.1 (2025-09-29)
205
+
206
+ ### Bug Fixes
207
+
208
+ - GitHub Enterprise with GH_HOST ([#11](https://github.com/watermarkhu/mkdocstrings-github/pull/11),
209
+ [`4f59dc0`](https://github.com/watermarkhu/mkdocstrings-github/commit/4f59dc07eb1f564d31431e4f3bf2e6fb1bcdfeb6))
210
+
211
+ ### Documentation
212
+
213
+ - Update docs ([#10](https://github.com/watermarkhu/mkdocstrings-github/pull/10),
214
+ [`3be05f5`](https://github.com/watermarkhu/mkdocstrings-github/commit/3be05f57605fbf12ab9c1ea8583775e1e47b25f2))
215
+
216
+
217
+ ## v0.2.0 (2025-09-28)
218
+
219
+ ### Features
220
+
221
+ - Cross-linking ([#9](https://github.com/watermarkhu/mkdocstrings-github/pull/9),
222
+ [`6bcf229`](https://github.com/watermarkhu/mkdocstrings-github/commit/6bcf229ad97702a44ba68ceb135ffd4b53208339))
223
+
224
+
225
+ ## v0.1.0 (2025-09-28)
226
+
227
+ - Initial Release
@@ -5,8 +5,13 @@ hide:
5
5
 
6
6
  --8<-- "README.md:header"
7
7
 
8
+ <p align="center"><img width=300px src="img/logo.png"></p>
9
+
8
10
  --8<-- "README.md:footer"
9
11
 
12
+ !!! note
13
+
14
+ Currently, only the [Material for MkDocs](https://github.com/squidfunk/mkdocs-material) theme is supported.
10
15
 
11
16
  ???+ example
12
17
 
@@ -25,6 +30,7 @@ hide:
25
30
  options:
26
31
  show_outputs: true
27
32
  signature_version: string
28
- signature_version_string: v1
33
+ signature_version_string: v5
34
+ signature_repository: actions/checkout
29
35
  show_source: false
30
36
  </div>
@@ -100,9 +100,6 @@ plugins:
100
100
 
101
101
  Some options are **global only**, and go directly under the handler's name.
102
102
 
103
- ::: mkdocstrings_handlers.github.config.GitHubConfig.repo
104
- handler: python
105
-
106
103
  ::: mkdocstrings_handlers.github.config.GitHubConfig.feather_icons_source
107
104
  handler: python
108
105
 
@@ -31,6 +31,28 @@
31
31
  options:
32
32
  show_signature: false
33
33
 
34
+ ::: mkdocstrings_handlers.github.config.GitHubOptions.signature_repository
35
+ handler: python
36
+
37
+ !!! tip
38
+
39
+ By default the current repository name is automatically grabbed from either the GitHub Actions environment or the git remotes.
40
+ This option only serves to *customize* the shown repository in the signature.
41
+
42
+ ??? preview
43
+
44
+ === "`signature_repository: username/repo`"
45
+
46
+ ::: .github/workflows/example_workflow.yml
47
+ options:
48
+ signature_repository: 'username/repo'
49
+
50
+ === "`signature_repository: organization/repository`"
51
+
52
+ ::: .github/workflows/example_workflow.yml
53
+ options:
54
+ signature_repository: organization/repository
55
+
34
56
  ::: mkdocstrings_handlers.github.config.GitHubOptions.signature_show_secrets
35
57
  handler: python
36
58
 
@@ -15,7 +15,6 @@ validation:
15
15
  nav:
16
16
  - Home:
17
17
  - Overview: index.md
18
- - Changelog: changelog.md
19
18
  - Contributing: contributing.md
20
19
  - Credits: credits.md
21
20
  - License: license-page.md
@@ -31,7 +30,7 @@ nav:
31
30
 
32
31
  theme:
33
32
  name: material
34
- logo: logo.png
33
+ logo: img/logo.png
35
34
  favicon: favicon.png
36
35
  custom_dir: docs/overrides
37
36
  features:
@@ -120,8 +119,8 @@ plugins:
120
119
  default_handler: github
121
120
  handlers:
122
121
  github:
123
- repo: owner/repository
124
122
  options:
123
+ signature_repository: owner/repository
125
124
  show_toc_entry: false
126
125
  heading_level: 3
127
126
  parameters_anchors: false
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "mkdocstrings-github"
3
- version = "0.4.5"
3
+ version = "0.5.1"
4
4
  description = "A GitHub Action handler for mkdocstrings"
5
5
  authors = [
6
6
  { name = "Mark Hu", email = "watermarkhu@gmail.com" }
@@ -2,7 +2,6 @@
2
2
 
3
3
  from __future__ import annotations
4
4
 
5
- import re
6
5
  import sys
7
6
  from typing import Literal
8
7
 
@@ -92,6 +91,15 @@ class GitHubOptions(BaseModel):
92
91
  description="Whether to show the signature in the documentation.",
93
92
  )
94
93
 
94
+ signature_repository: str = Field(
95
+ default="",
96
+ description="""The GitHub repository in the format *owner/repo*.
97
+
98
+ By default, the repository is inferred from the current git repository using the default origin remote.
99
+ If it cannot be inferred, it must be set manually.
100
+ """,
101
+ )
102
+
95
103
  signature_show_secrets: bool = Field(
96
104
  default=False,
97
105
  description="Whether to show secrets in the signature.",
@@ -171,16 +179,6 @@ class GitHubOptions(BaseModel):
171
179
  class GitHubConfig(BaseModel):
172
180
  """Configuration options for the GitHub handler."""
173
181
 
174
- repo: str = Field(
175
- default="",
176
- description="""The GitHub repository in the format *owner/repo*.
177
-
178
- By default, the repository is inferred from the current git repository using the default origin remote.
179
- If it cannot be inferred, it must be set manually.
180
- """,
181
- pattern=re.compile(r"^[\w.-]+/[\w.-]+$"),
182
- )
183
-
184
182
  feather_icons_source: str = Field(
185
183
  default="https://cdn.jsdelivr.net/npm/feather-icons/dist/feather.min.js",
186
184
  description="""The source URL for Feather icons.