Skip to content

Commit

Permalink
Use mkdocs plugin to put last update time on pages
Browse files Browse the repository at this point in the history
The git-revision-date-localized plugin will automatically add
the last update date to each markdown page based on the date
of the last change in git to the file.

Signed-off-by: Eric Brown <[email protected]>
  • Loading branch information
ericwb committed Nov 11, 2024
1 parent 7f50fcb commit d55a930
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 9 deletions.
3 changes: 0 additions & 3 deletions docs/getting-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,3 @@ repos:
```

Then run `pre-commit install` and you're ready to go.


_Last updated on {{ git.date.strftime("%b %d, %Y") }}_
2 changes: 0 additions & 2 deletions docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,5 +40,3 @@ vulnerabilities.
[:octicons-arrow-right-24: License](https://github.com/securesauce/precli/blob/main/LICENSE)

</div>

_Last updated on {{ git.date.strftime("%b %d, %Y") }}_
5 changes: 3 additions & 2 deletions docs/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# Copyright 2024 Secure Sauce LLC
# SPDX-License-Identifier: BUSL-1.1
mkdocs
mkdocstrings[python]
mkdocs-material
mkdocs-macros-plugin
mkdocs-material
mkdocs-git-revision-date-localized-plugin
mkdocstrings[python]
2 changes: 0 additions & 2 deletions docs/rules.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,5 +70,3 @@
| PY044 | [telnetlib — no timeout](rules/python/stdlib/telnetlib-no-timeout.md) | Synchronous Access of `Telnet` without Timeout |
| PY045 | [ftplib — no timeout](rules/python/stdlib/ftplib-no-timeout.md) | Synchronous Access of `FTP` without Timeout |
| PY046 | [ssl — no timeout](rules/python/stdlib/ssl-no-timeout.md) | Synchronous Access of `ssl` without Timeout |

_Last updated on {{ git.date.strftime("%b %d, %Y") }}_
1 change: 1 addition & 0 deletions mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ plugins:
- mkdocstrings
- search
- macros
- git-revision-date-localized

nav:
- Home: index.md
Expand Down

0 comments on commit d55a930

Please sign in to comment.