documenteer 2.3.0__tar.gz → 2.4.0__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.
- {documenteer-2.3.0 → documenteer-2.4.0}/.github/workflows/ci-cron.yaml +9 -9
- {documenteer-2.3.0 → documenteer-2.4.0}/.github/workflows/ci.yaml +11 -11
- {documenteer-2.3.0 → documenteer-2.4.0}/CHANGELOG.md +17 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/Makefile +1 -1
- {documenteer-2.3.0/src/documenteer.egg-info → documenteer-2.4.0}/PKG-INFO +1 -1
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/changelog.md +17 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/dev/api/documenteer.ext.rst +3 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/documenteer.toml +5 -1
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/guides/toml-reference.rst +41 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/sphinx-extensions/index.rst +7 -0
- documenteer-2.4.0/docs/sphinx-extensions/last-updated.rst +137 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/pyproject.toml +1 -3
- documenteer-2.4.0/src/documenteer/assets/rubin-last-modified.js +45 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/assets/rubin-pydata-theme.css +22 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/conf/_toml.py +18 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/conf/_utils.py +70 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/conf/guide.py +26 -0
- documenteer-2.4.0/src/documenteer/ext/lastmodified.py +402 -0
- documenteer-2.4.0/src/documenteer/templates/pydata/last-updated.html +14 -0
- {documenteer-2.3.0 → documenteer-2.4.0/src/documenteer.egg-info}/PKG-INFO +1 -1
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer.egg-info/SOURCES.txt +11 -0
- documenteer-2.4.0/tests/ext/lastmodified_test.py +347 -0
- documenteer-2.4.0/tests/roots/test-lastmodified/conf.py +8 -0
- documenteer-2.4.0/tests/roots/test-lastmodified/index.rst +12 -0
- documenteer-2.4.0/tests/roots/test-lastmodified/page2.rst +5 -0
- documenteer-2.4.0/tests/roots/test-lastmodified/snippet.txt +1 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/test_conf_toml.py +30 -0
- documenteer-2.4.0/tests/test_git_repository.py +125 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tox.ini +1 -0
- documenteer-2.4.0/uv.lock +2664 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/.claude/.gitignore +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/.claude/tasks/.gitkeep +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/.flake8 +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/.github/CODE_OF_CONDUCT.md +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/.github/CONTRIBUTING.md +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/.github/SUPPORT.md +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/.github/dependabot.yml +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/.gitignore +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/.npmrc +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/.nvmrc +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/.pre-commit-config.yaml +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/.prettierignore +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/.prettierrc.yaml +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/.vscode/settings.json +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/.vscode/tasks.json +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/CLAUDE.md +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/LICENSE +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/MANIFEST.in +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/README.md +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/changelog.d/_template.md.jinja +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/demo/ipynb-technote/.gitignore +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/demo/ipynb-technote/Makefile +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/demo/ipynb-technote/conf.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/demo/ipynb-technote/diagram.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/demo/ipynb-technote/extra-notebook.ipynb +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/demo/ipynb-technote/index.ipynb +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/demo/ipynb-technote/subdir/subdir-notebook.ipynb +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/demo/ipynb-technote/technote.toml +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/demo/md-technote/.gitignore +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/demo/md-technote/Makefile +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/demo/md-technote/conf.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/demo/md-technote/diagram.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/demo/md-technote/index.md +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/demo/md-technote/technote.toml +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/demo/rst-technote/.gitignore +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/demo/rst-technote/Makefile +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/demo/rst-technote/conf.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/demo/rst-technote/diagram.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/demo/rst-technote/index.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/demo/rst-technote/local.bib +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/demo/rst-technote/technote.toml +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/.gitignore +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/Makefile +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/_rst_epilog.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/conf.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/dev/api/documenteer.conf.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/dev/api/index.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/dev/development.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/dev/html-templates.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/dev/index.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/dev/release.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/dev/theme-assets.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/dev/theme.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/guides/badges.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/guides/configuration-preset.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/guides/configuration.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/guides/diagrams.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/guides/extend-conf-py.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/guides/including-notebooks.ipynb +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/guides/index.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/guides/markdown-primer.md +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/guides/openapi.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/guides/organization.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/guides/overview.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/guides/page-redirects.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/guides/pyproject-configuration.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/guides/rst-epilog.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/guides/tabsets.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/guides/video-embeds.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/index.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/sphinx-extensions/docushare-reference.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/sphinx-extensions/githubbibcache.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/sphinx-extensions/jira-reference.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/sphinx-extensions/lsst-pybtex-style.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/sphinx-extensions/openapi.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/sphinx-extensions/remote-code-block.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/technotes/_templates/README.md +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/technotes/_templates/README.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/technotes/author-metadata.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/technotes/configuration.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/technotes/document-status.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/technotes/edit-locally.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/technotes/edit-on-github.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/technotes/extensions.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/technotes/how-your-technote-gets-published.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/technotes/index.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/technotes/migrate.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/technotes/references.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/technotes/start-a-technote.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/docs/technotes/wide-content.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/licenses/README.md +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/licenses/astropy-helpers.txt +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/licenses/sphinx-issue.txt +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/licenses/sphinx.txt +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/licenses/sphinxcontrib-redoc.txt +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/package-lock.json +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/package.json +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/postcss.config.js +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/ruff-shared.toml +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/setup.cfg +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/assets/rubin-technote/styles/SourceSans3VF-Italic.ttf.woff2 +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/assets/rubin-technote/styles/SourceSans3VF-Upright.ttf.woff2 +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/assets/rubin-technote/styles/_hacks.scss +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/assets/rubin-technote/styles/_properties.scss +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/assets/rubin-technote/styles/components/_article-header.scss +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/assets/rubin-technote/styles/components/_authors.scss +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/assets/rubin-technote/styles/components/_global-breadcrumbs.scss +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/assets/rubin-technote/styles/components/_index.scss +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/assets/rubin-technote/styles/components/_sidebar-section.scss +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/assets/rubin-technote/styles/components/_version-info.scss +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/assets/rubin-technote/styles/rubin-technote.scss +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/__init__.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/_packagemetadata.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/_requestsutils.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/_utils.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/assets/.gitignore +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/assets/731c8feefe13e72a8691.woff2 +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/assets/b8bc3440ba2145e132f5.woff2 +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/assets/favicon.ico +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/assets/rsd-assets/rubin-imagotype-color-on-black-crop.svg +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/assets/rsd-assets/rubin-imagotype-color-on-white-crop.svg +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/assets/rubin-favicon-transparent-32px.png +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/assets/rubin-favicon.svg +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/assets/rubin-technote.css +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/assets/rubin-technote.css.map +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/assets/rubin-titlebar-imagotype-dark.svg +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/assets/rubin-titlebar-imagotype-light.svg +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/assets/scripts/rubin-technote.js +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/assets/scripts/rubin-technote.js.map +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/cli.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/conf/__init__.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/conf/technote.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/ext/__init__.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/ext/bibtex.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/ext/githubbibcache.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/ext/jira.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/ext/lsstdocushare.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/ext/mockcoderefs.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/ext/openapi.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/ext/redoc/__init__.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/ext/redoc/_redoc.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/ext/redoc/assets/redoc.html.jinja2 +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/ext/remotecodeblock.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/ext/robots.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/py.typed +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/services/__init__.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/services/technoteauthor.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/services/technotemigration.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/storage/__init__.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/storage/authordb.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/storage/latex.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/storage/localtemplates/technote/Makefile +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/storage/localtemplates/technote/README.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/storage/localtemplates/technote/ci.yaml +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/storage/localtemplates/technote/conf.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/storage/localtemplates/technote/dependabot.yml +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/storage/localtemplates/technote/gitignore +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/storage/localtemplates/technote/pre-commit-config.yaml +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/storage/localtemplates/technote/requirements.txt +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/storage/localtemplates/technote/tox.ini +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/storage/localtemplates.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/storage/technotetoml.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/templates/pydata/autosummary_core/exception.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/templates/pydata/autosummary_core/pydantic_model.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/templates/pydata/layout.html +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/templates/technote/.gitkeep +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/templates/technote/components/.gitkeep +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/templates/technote/components/sidebar-source.html +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/templates/technote/sections/.gitkeep +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/templates/technote/sections/header-article.html +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/templates/technote/sections/sidebar-primary.html +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer/version.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer.egg-info/dependency_links.txt +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer.egg-info/entry_points.txt +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer.egg-info/requires.txt +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/src/documenteer.egg-info/top_level.txt +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/__init__.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/conftest.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/data/afw.doxygen.conf +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/data/authordb.yaml +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/data/doxygen.tag.zip +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/data/package_alpha/doc/_static/package_alpha/README.md +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/data/package_alpha/doc/doxygen.conf.in +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/data/package_alpha/doc/manifest.yaml +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/data/package_alpha/doc/package.alpha/index.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/data/package_alpha/doc/package_alpha/index.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/data/package_alpha/include/README.md +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/data/package_alpha/src/README.md +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/data/package_beta/doc/README.md +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/ext/__init__.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/ext/jira_test.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/ext/lsstdocushare_test.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/ext/mockcoderefs_test.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/ext/redoc_test.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/ext/robots_test.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/packagemetadata_test.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/roots/test-autocppapi/conf.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/roots/test-autocppapi/doxygen.tag.zip +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/roots/test-autocppapi/index.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/roots/test-redoc/_static/openapi.json +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/roots/test-redoc/api.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/roots/test-redoc/conf.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/roots/test-redoc/documenteer.toml +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/roots/test-redoc/index.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/roots/test-robots-nositemap/conf.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/roots/test-robots-nositemap/index.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/roots/test-robots-nositemap/page1.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/roots/test-robots-sitemap/conf.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/roots/test-robots-sitemap/index.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/roots/test-robots-sitemap/page1.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/roots/test-robots-sitemap/page2.rst +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/services/__init__.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/services/technotemigration_test.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/storage/__init__.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/storage/authordb_test.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/storage/technotetoml_test.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/tests/test_conf_utils.py +0 -0
- {documenteer-2.3.0 → documenteer-2.4.0}/webpack.config.js +0 -0
|
@@ -16,14 +16,14 @@ jobs:
|
|
|
16
16
|
lint:
|
|
17
17
|
runs-on: ubuntu-latest
|
|
18
18
|
steps:
|
|
19
|
-
- uses: actions/checkout@
|
|
19
|
+
- uses: actions/checkout@v6
|
|
20
20
|
|
|
21
21
|
- name: Set up Python
|
|
22
|
-
uses: actions/setup-python@
|
|
22
|
+
uses: actions/setup-python@v6
|
|
23
23
|
with:
|
|
24
24
|
python-version: ${{ env.PYTHON_VERSION }}
|
|
25
25
|
|
|
26
|
-
- uses: actions/setup-node@
|
|
26
|
+
- uses: actions/setup-node@v6
|
|
27
27
|
with:
|
|
28
28
|
cache: 'npm'
|
|
29
29
|
node-version-file: '.nvmrc'
|
|
@@ -71,11 +71,11 @@ jobs:
|
|
|
71
71
|
- "dev"
|
|
72
72
|
|
|
73
73
|
steps:
|
|
74
|
-
- uses: actions/checkout@
|
|
74
|
+
- uses: actions/checkout@v6
|
|
75
75
|
with:
|
|
76
76
|
fetch-depth: 0 # full history for setuptools_scm
|
|
77
77
|
|
|
78
|
-
- uses: actions/setup-node@
|
|
78
|
+
- uses: actions/setup-node@v6
|
|
79
79
|
with:
|
|
80
80
|
node-version-file: '.nvmrc'
|
|
81
81
|
|
|
@@ -115,11 +115,11 @@ jobs:
|
|
|
115
115
|
runs-on: ubuntu-latest
|
|
116
116
|
|
|
117
117
|
steps:
|
|
118
|
-
- uses: actions/checkout@
|
|
118
|
+
- uses: actions/checkout@v6
|
|
119
119
|
with:
|
|
120
120
|
fetch-depth: 0 # full history for setuptools_scm
|
|
121
121
|
|
|
122
|
-
- uses: actions/setup-node@
|
|
122
|
+
- uses: actions/setup-node@v6
|
|
123
123
|
with:
|
|
124
124
|
cache: 'npm'
|
|
125
125
|
node-version-file: '.nvmrc'
|
|
@@ -160,11 +160,11 @@ jobs:
|
|
|
160
160
|
runs-on: ubuntu-latest
|
|
161
161
|
|
|
162
162
|
steps:
|
|
163
|
-
- uses: actions/checkout@
|
|
163
|
+
- uses: actions/checkout@v6
|
|
164
164
|
with:
|
|
165
165
|
fetch-depth: 0 # full history for setuptools_scm
|
|
166
166
|
|
|
167
|
-
- uses: actions/setup-node@
|
|
167
|
+
- uses: actions/setup-node@v6
|
|
168
168
|
with:
|
|
169
169
|
node-version-file: '.nvmrc'
|
|
170
170
|
|
|
@@ -22,14 +22,14 @@ jobs:
|
|
|
22
22
|
lint:
|
|
23
23
|
runs-on: ubuntu-latest
|
|
24
24
|
steps:
|
|
25
|
-
- uses: actions/checkout@
|
|
25
|
+
- uses: actions/checkout@v6
|
|
26
26
|
|
|
27
27
|
- name: Set up Python
|
|
28
|
-
uses: actions/setup-python@
|
|
28
|
+
uses: actions/setup-python@v6
|
|
29
29
|
with:
|
|
30
30
|
python-version: ${{ env.PYTHON_VERSION }}
|
|
31
31
|
|
|
32
|
-
- uses: actions/setup-node@
|
|
32
|
+
- uses: actions/setup-node@v6
|
|
33
33
|
with:
|
|
34
34
|
cache: 'npm'
|
|
35
35
|
node-version-file: '.nvmrc'
|
|
@@ -65,11 +65,11 @@ jobs:
|
|
|
65
65
|
- '8'
|
|
66
66
|
|
|
67
67
|
steps:
|
|
68
|
-
- uses: actions/checkout@
|
|
68
|
+
- uses: actions/checkout@v6
|
|
69
69
|
with:
|
|
70
70
|
fetch-depth: 0 # full history for setuptools_scm
|
|
71
71
|
|
|
72
|
-
- uses: actions/setup-node@
|
|
72
|
+
- uses: actions/setup-node@v6
|
|
73
73
|
with:
|
|
74
74
|
cache: 'npm'
|
|
75
75
|
node-version-file: '.nvmrc'
|
|
@@ -99,14 +99,14 @@ jobs:
|
|
|
99
99
|
runs-on: ubuntu-latest
|
|
100
100
|
|
|
101
101
|
steps:
|
|
102
|
-
- uses: actions/checkout@
|
|
102
|
+
- uses: actions/checkout@v6
|
|
103
103
|
with:
|
|
104
104
|
fetch-depth: 0 # full history for setuptools_scm
|
|
105
105
|
|
|
106
106
|
- name: Setup Graphviz
|
|
107
107
|
uses: ts-graphviz/setup-graphviz@v2
|
|
108
108
|
|
|
109
|
-
- uses: actions/setup-node@
|
|
109
|
+
- uses: actions/setup-node@v6
|
|
110
110
|
with:
|
|
111
111
|
cache: 'npm'
|
|
112
112
|
node-version-file: '.nvmrc'
|
|
@@ -148,11 +148,11 @@ jobs:
|
|
|
148
148
|
runs-on: ubuntu-latest
|
|
149
149
|
|
|
150
150
|
steps:
|
|
151
|
-
- uses: actions/checkout@
|
|
151
|
+
- uses: actions/checkout@v6
|
|
152
152
|
with:
|
|
153
153
|
fetch-depth: 0 # full history for setuptools_scm
|
|
154
154
|
|
|
155
|
-
- uses: actions/setup-node@
|
|
155
|
+
- uses: actions/setup-node@v6
|
|
156
156
|
with:
|
|
157
157
|
cache: 'npm'
|
|
158
158
|
node-version-file: '.nvmrc'
|
|
@@ -185,11 +185,11 @@ jobs:
|
|
|
185
185
|
if: github.event_name == 'release' && github.event.action == 'published'
|
|
186
186
|
|
|
187
187
|
steps:
|
|
188
|
-
- uses: actions/checkout@
|
|
188
|
+
- uses: actions/checkout@v6
|
|
189
189
|
with:
|
|
190
190
|
fetch-depth: 0 # full history for setuptools_scm
|
|
191
191
|
|
|
192
|
-
- uses: actions/setup-node@
|
|
192
|
+
- uses: actions/setup-node@v6
|
|
193
193
|
with:
|
|
194
194
|
cache: 'npm'
|
|
195
195
|
node-version-file: '.nvmrc'
|
|
@@ -2,6 +2,23 @@
|
|
|
2
2
|
|
|
3
3
|
<!-- scriv-insert-here -->
|
|
4
4
|
|
|
5
|
+
<a id='changelog-2.4.0'></a>
|
|
6
|
+
## 2.4.0 (2026-06-17)
|
|
7
|
+
|
|
8
|
+
### New features
|
|
9
|
+
|
|
10
|
+
- User guide pages now show a "This page was last modified on <date>." timestamp at the bottom of each page, derived from the page's Git commit history. The date is the most recent commit across the page's own source file and any files it pulls in via `include`/`literalinclude`, so editing an included snippet updates every page that uses it. This is on by default and can be disabled with `show_last_updated = false` in the `[sphinx.theme]` table of `documenteer.toml`.
|
|
11
|
+
|
|
12
|
+
The footer date is rendered as a `<time>` element whose `datetime` attribute carries the canonical UTC ISO 8601 timestamp, and a small bundled script (`rubin-last-modified.js`) rewrites the visible text to the reader's own local date (for example "June 1, 2024"). With JavaScript disabled the element falls back to the UTC date as `YYYY-MM-DD`. This ensures readers in any timezone see the correct calendar day, which a fixed UTC date can otherwise misrepresent.
|
|
13
|
+
|
|
14
|
+
The extension is also the single source of truth for the page's last-modified date in the HTML `<head>`: it emits the same Git date as an `article:modified_time` (Open Graph), `dcterms.modified` (Dublin Core), and a Schema.org `dateModified` (JSON-LD). The user-guide preset sets `git_last_updated_metatags = false` so the auto-loaded `sphinx-last-updated-by-git` extension (still used for the sitemap) doesn't emit a duplicate Open Graph tag from a separate Git computation.
|
|
15
|
+
|
|
16
|
+
Because the date comes from Git, CI builds must check out the full history (set `fetch-depth: 0` with `actions/checkout`). To avoid publishing misleading dates, Documenteer detects a shallow clone, omits the timestamp from every page, and emits a build warning.
|
|
17
|
+
|
|
18
|
+
### Other changes
|
|
19
|
+
|
|
20
|
+
- Fixed pytest configuration in `pyproject.toml` by consolidating conflicting `[tool.pytest]` and `[tool.pytest.ini_options]` sections into a single `[tool.pytest.ini_options]` section. This resolves an error that prevented tests from running.
|
|
21
|
+
|
|
5
22
|
<a id='changelog-2.3.0'></a>
|
|
6
23
|
## 2.3.0 (2025-09-03)
|
|
7
24
|
|
|
@@ -2,6 +2,23 @@
|
|
|
2
2
|
|
|
3
3
|
<!-- scriv-insert-here -->
|
|
4
4
|
|
|
5
|
+
<a id='changelog-2.4.0'></a>
|
|
6
|
+
## 2.4.0 (2026-06-17)
|
|
7
|
+
|
|
8
|
+
### New features
|
|
9
|
+
|
|
10
|
+
- User guide pages now show a "This page was last modified on <date>." timestamp at the bottom of each page, derived from the page's Git commit history. The date is the most recent commit across the page's own source file and any files it pulls in via `include`/`literalinclude`, so editing an included snippet updates every page that uses it. This is on by default and can be disabled with `show_last_updated = false` in the `[sphinx.theme]` table of `documenteer.toml`.
|
|
11
|
+
|
|
12
|
+
The footer date is rendered as a `<time>` element whose `datetime` attribute carries the canonical UTC ISO 8601 timestamp, and a small bundled script (`rubin-last-modified.js`) rewrites the visible text to the reader's own local date (for example "June 1, 2024"). With JavaScript disabled the element falls back to the UTC date as `YYYY-MM-DD`. This ensures readers in any timezone see the correct calendar day, which a fixed UTC date can otherwise misrepresent.
|
|
13
|
+
|
|
14
|
+
The extension is also the single source of truth for the page's last-modified date in the HTML `<head>`: it emits the same Git date as an `article:modified_time` (Open Graph), `dcterms.modified` (Dublin Core), and a Schema.org `dateModified` (JSON-LD). The user-guide preset sets `git_last_updated_metatags = false` so the auto-loaded `sphinx-last-updated-by-git` extension (still used for the sitemap) doesn't emit a duplicate Open Graph tag from a separate Git computation.
|
|
15
|
+
|
|
16
|
+
Because the date comes from Git, CI builds must check out the full history (set `fetch-depth: 0` with `actions/checkout`). To avoid publishing misleading dates, Documenteer detects a shallow clone, omits the timestamp from every page, and emits a build warning.
|
|
17
|
+
|
|
18
|
+
### Other changes
|
|
19
|
+
|
|
20
|
+
- Fixed pytest configuration in `pyproject.toml` by consolidating conflicting `[tool.pytest]` and `[tool.pytest.ini_options]` sections into a single `[tool.pytest.ini_options]` section. This resolves an error that prevented tests from running.
|
|
21
|
+
|
|
5
22
|
<a id='changelog-2.3.0'></a>
|
|
6
23
|
## 2.3.0 (2025-09-03)
|
|
7
24
|
|
|
@@ -45,7 +45,11 @@ technote = "https://technote.lsst.io/"
|
|
|
45
45
|
[sphinx.linkcheck]
|
|
46
46
|
ignore = [
|
|
47
47
|
"https://mermaid-js.github.io",
|
|
48
|
-
"https://rubin-obs.slack.com"
|
|
48
|
+
"https://rubin-obs.slack.com",
|
|
49
|
+
"https://slack.com/app_redirect",
|
|
50
|
+
# github.dev redirects to the vscode.dev SPA, which doesn't finish
|
|
51
|
+
# loading within linkcheck's timeout and reports a false-positive timeout.
|
|
52
|
+
"https://github.dev",
|
|
49
53
|
]
|
|
50
54
|
|
|
51
55
|
[sphinx.redirects]
|
|
@@ -426,6 +426,47 @@ This configuration requires information about the GitHub repository from these o
|
|
|
426
426
|
- :ref:`project.github_url <guide-project-github-url>`
|
|
427
427
|
- :ref:`project.github_default_branch <guide-project-github-default-branch>`
|
|
428
428
|
|
|
429
|
+
.. _guide-project-show-last-updated:
|
|
430
|
+
|
|
431
|
+
show_last_updated
|
|
432
|
+
-----------------
|
|
433
|
+
|
|
434
|
+
|optional|
|
|
435
|
+
|
|
436
|
+
Default is ``true``, so that each page shows a "Last updated on <date>." timestamp at the bottom of each page.
|
|
437
|
+
|
|
438
|
+
.. seealso::
|
|
439
|
+
|
|
440
|
+
:doc:`/sphinx-extensions/last-updated` for how the date is computed and the extension's
|
|
441
|
+
Sphinx configuration values.
|
|
442
|
+
|
|
443
|
+
The date is computed from the page's **Git commit history**, not the filesystem modification time (which is meaningless in CI).
|
|
444
|
+
It is the most recent commit date across the page's own source file *and* any files the page pulls in with ``include`` or ``literalinclude`` directives, so editing an included snippet updates every page that uses it.
|
|
445
|
+
Because the date is the last *commit* date, uncommitted local edits don't change it; a page whose source has never been committed shows no timestamp.
|
|
446
|
+
|
|
447
|
+
Set this to ``false`` to hide the timestamp:
|
|
448
|
+
|
|
449
|
+
.. code-block:: toml
|
|
450
|
+
:caption: documenteer.toml
|
|
451
|
+
|
|
452
|
+
[sphinx.theme]
|
|
453
|
+
show_last_updated = false
|
|
454
|
+
|
|
455
|
+
.. important::
|
|
456
|
+
|
|
457
|
+
Because the date comes from the Git history, your CI build must check out the **full** commit history.
|
|
458
|
+
With `actions/checkout <https://github.com/actions/checkout>`__, set ``fetch-depth: 0``:
|
|
459
|
+
|
|
460
|
+
.. code-block:: yaml
|
|
461
|
+
:caption: .github/workflows/ci.yaml
|
|
462
|
+
|
|
463
|
+
- uses: actions/checkout@v6
|
|
464
|
+
with:
|
|
465
|
+
fetch-depth: 0
|
|
466
|
+
|
|
467
|
+
A shallow clone (the default) only fetches the most recent commit, so every page would otherwise report the same, incorrect date.
|
|
468
|
+
To avoid publishing misleading data, Documenteer detects a shallow clone, **omits the "Last updated" timestamp from every page**, and emits a single build warning telling you to set ``fetch-depth: 0``.
|
|
469
|
+
|
|
429
470
|
[sphinx.intersphinx]
|
|
430
471
|
====================
|
|
431
472
|
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
.. _documenteer-ext-lastmodified:
|
|
2
|
+
|
|
3
|
+
##############################
|
|
4
|
+
"Last updated" page timestamps
|
|
5
|
+
##############################
|
|
6
|
+
|
|
7
|
+
Documenteer's ``documenteer.ext.lastmodified`` extension adds a "This page was last modified on <date>." timestamp to the bottom of each page's article body.
|
|
8
|
+
The date is derived from the page's **Git commit history** rather than the filesystem modification time, which is meaningless in CI where checkouts have arbitrary timestamps.
|
|
9
|
+
In the user-guide preset the footer date is rendered to the **reader's** local timezone (see `Reader-localized footer date`_).
|
|
10
|
+
It is also the single source of truth for the page's last-modified date in the HTML ``<head>``, where it emits the same Git date as Open Graph, Dublin Core, and Schema.org metadata (see `HTML metadata`_).
|
|
11
|
+
|
|
12
|
+
The extension exposes the date to the page template in three forms:
|
|
13
|
+
|
|
14
|
+
- ``last_updated`` — the date formatted with :ref:`documenteer_last_modified_date_format <documenteer-last-modified-date-format-conf>` in the commit's own timezone offset. Sphinx emits this as the ``docbuild:last-update`` meta tag, and it is the value any theme-agnostic ``last-updated`` rendering uses.
|
|
15
|
+
- ``documenteer_last_modified_iso`` — the canonical UTC ISO 8601 timestamp (for example ``2024-06-01T00:00:00+00:00``).
|
|
16
|
+
- ``documenteer_last_modified_date`` — the UTC date as ``YYYY-MM-DD`` (for example ``2024-06-01``).
|
|
17
|
+
|
|
18
|
+
Reader-localized footer date
|
|
19
|
+
============================
|
|
20
|
+
|
|
21
|
+
In the user-guide preset, Documenteer overrides pydata-sphinx-theme's ``last-updated`` component to render the footer date as a ``<time>`` element:
|
|
22
|
+
|
|
23
|
+
.. code-block:: html
|
|
24
|
+
|
|
25
|
+
<time datetime="2024-06-01T00:00:00+00:00">2024-06-01</time>
|
|
26
|
+
|
|
27
|
+
The ``datetime`` attribute carries the canonical UTC ISO 8601 timestamp, and the visible text is the UTC date as ``YYYY-MM-DD``.
|
|
28
|
+
A small bundled script (``rubin-last-modified.js``) then rewrites the visible text to the **reader's** local date in a long-month style, for example "June 1, 2024".
|
|
29
|
+
This matters because a UTC date can fall on a different calendar day than the reader's local date; localizing in the browser shows each reader the correct day.
|
|
30
|
+
With JavaScript disabled the element keeps its ``YYYY-MM-DD`` UTC fallback text.
|
|
31
|
+
|
|
32
|
+
.. tip::
|
|
33
|
+
|
|
34
|
+
If you use Documenteer's user-guide configuration preset, this extension is already enabled and the timestamp is shown by default.
|
|
35
|
+
Toggle it with the :ref:`show_last_updated <guide-project-show-last-updated>` setting in :file:`documenteer.toml`; you don't need to edit :file:`conf.py`.
|
|
36
|
+
|
|
37
|
+
How the date is computed
|
|
38
|
+
========================
|
|
39
|
+
|
|
40
|
+
The timestamp is the most recent commit date across the page's own source file *and* any files it pulls in with the ``include`` or ``literalinclude`` directives.
|
|
41
|
+
Editing an included snippet therefore updates the timestamp on every page that uses it.
|
|
42
|
+
|
|
43
|
+
Because the date is the last *commit* date:
|
|
44
|
+
|
|
45
|
+
- Uncommitted local edits don't change it.
|
|
46
|
+
- A page whose source has never been committed shows no timestamp.
|
|
47
|
+
- Generated pages without a source document (such as the search page and general index) show no timestamp.
|
|
48
|
+
|
|
49
|
+
HTML metadata
|
|
50
|
+
=============
|
|
51
|
+
|
|
52
|
+
Besides the visible footer timestamp, the extension writes the **same Git commit date** into the page's HTML ``<head>`` as three machine-readable signals, so that downstream consumers all agree:
|
|
53
|
+
|
|
54
|
+
- ``<meta property="article:modified_time">`` — the `Open Graph <https://ogp.me/>`__ property used by social-media link previews.
|
|
55
|
+
- ``<meta name="dcterms.modified">`` — the `Dublin Core <https://www.dublincore.org/specifications/dublin-core/dcmi-terms/#modified>`__ modification date.
|
|
56
|
+
- A `Schema.org <https://schema.org/dateModified>`__ ``dateModified`` field inside a JSON-LD ``<script type="application/ld+json">`` block (typed as ``WebPage``).
|
|
57
|
+
|
|
58
|
+
These three head signals are expressed in **UTC** (ISO 8601, ``+00:00``), so the metadata is identical regardless of the committer's timezone — a locally-authored commit and its UTC-recorded squash-merge produce the same value.
|
|
59
|
+
The visible footer date, by contrast, reflects the commit's own offset.
|
|
60
|
+
|
|
61
|
+
In addition, pydata-sphinx-theme renders a ``<meta name="docbuild:last-update">`` tag from the same ``last_updated`` context value.
|
|
62
|
+
|
|
63
|
+
.. note::
|
|
64
|
+
|
|
65
|
+
sphinx-sitemap (enabled by the user-guide preset) auto-loads `sphinx-last-updated-by-git <https://github.com/mgeier/sphinx-last-updated-by-git>`__ to populate the sitemap's ``<lastmod>`` entries.
|
|
66
|
+
That extension runs its *own* Git computation and would otherwise emit a second, potentially divergent ``article:modified_time`` tag.
|
|
67
|
+
To keep this extension the single source of truth, the user-guide preset sets ``git_last_updated_metatags = False``, which silences the duplicate Open Graph tag while leaving the sitemap behavior intact.
|
|
68
|
+
|
|
69
|
+
Full Git history is required
|
|
70
|
+
============================
|
|
71
|
+
|
|
72
|
+
The date comes from Git, so the build must have the **full** commit history.
|
|
73
|
+
|
|
74
|
+
.. important::
|
|
75
|
+
|
|
76
|
+
With `actions/checkout <https://github.com/actions/checkout>`__, set ``fetch-depth: 0``:
|
|
77
|
+
|
|
78
|
+
.. code-block:: yaml
|
|
79
|
+
:caption: .github/workflows/ci.yaml
|
|
80
|
+
|
|
81
|
+
- uses: actions/checkout@v6
|
|
82
|
+
with:
|
|
83
|
+
fetch-depth: 0
|
|
84
|
+
|
|
85
|
+
A shallow clone (the default) only fetches the most recent commit, so every page would otherwise report the same, incorrect date.
|
|
86
|
+
To avoid publishing misleading data, Documenteer detects a shallow clone, omits the timestamp from every page, and emits a single build warning.
|
|
87
|
+
|
|
88
|
+
Reference
|
|
89
|
+
=========
|
|
90
|
+
|
|
91
|
+
Extension module
|
|
92
|
+
----------------
|
|
93
|
+
|
|
94
|
+
The user-guide configuration preset enables this extension automatically.
|
|
95
|
+
To use it in a standalone Sphinx project, add ``"documenteer.ext.lastmodified"`` to the extensions list in :file:`conf.py` and render the ``last_updated`` context value.
|
|
96
|
+
With pydata-sphinx-theme, add the ``last-updated`` component to the article footer:
|
|
97
|
+
|
|
98
|
+
.. code-block:: python
|
|
99
|
+
:caption: conf.py
|
|
100
|
+
|
|
101
|
+
extensions = ["documenteer.ext.lastmodified", ...]
|
|
102
|
+
|
|
103
|
+
html_theme = "pydata_sphinx_theme"
|
|
104
|
+
html_theme_options = {
|
|
105
|
+
"article_footer_items": ["last-updated"],
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
Configurations
|
|
109
|
+
--------------
|
|
110
|
+
|
|
111
|
+
Set these configurations in the Sphinx :file:`conf.py` file.
|
|
112
|
+
|
|
113
|
+
.. _documenteer-last-modified-enabled-conf:
|
|
114
|
+
|
|
115
|
+
documenteer\_last\_modified\_enabled
|
|
116
|
+
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
117
|
+
|
|
118
|
+
Whether to compute and show the "Last updated" timestamp.
|
|
119
|
+
A boolean that defaults to `True`.
|
|
120
|
+
In the user-guide preset this is set automatically from the :ref:`show_last_updated <guide-project-show-last-updated>` field in :file:`documenteer.toml`.
|
|
121
|
+
|
|
122
|
+
.. _documenteer-last-modified-date-format-conf:
|
|
123
|
+
|
|
124
|
+
documenteer\_last\_modified\_date\_format
|
|
125
|
+
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
126
|
+
|
|
127
|
+
The ``strftime``-style format string for the ``last_updated`` value.
|
|
128
|
+
Defaults to ``"%b %d, %Y"`` (for example, ``Jun 16, 2026``).
|
|
129
|
+
The date is formatted with Sphinx's date machinery, so it respects the build's ``language`` setting.
|
|
130
|
+
|
|
131
|
+
This format governs the ``last_updated`` context value — the ``docbuild:last-update`` meta tag and any theme-agnostic ``last-updated`` rendering — **not** the visible footer date in the user-guide preset.
|
|
132
|
+
That footer date is rendered from the UTC ISO timestamp and localized to the reader's timezone by JavaScript (see `Reader-localized footer date`_), so it is not affected by this setting.
|
|
133
|
+
|
|
134
|
+
.. code-block:: python
|
|
135
|
+
:caption: conf.py
|
|
136
|
+
|
|
137
|
+
documenteer_last_modified_date_format = "%Y-%m-%d"
|
|
@@ -163,10 +163,8 @@ exclude_lines = [
|
|
|
163
163
|
"if TYPE_CHECKING:",
|
|
164
164
|
]
|
|
165
165
|
|
|
166
|
-
[tool.pytest]
|
|
167
|
-
norecursedirs = "node_modules"
|
|
168
|
-
|
|
169
166
|
[tool.pytest.ini_options]
|
|
167
|
+
norecursedirs = "node_modules"
|
|
170
168
|
python_files = ["tests/*.py", "tests/*/*.py"]
|
|
171
169
|
|
|
172
170
|
[tool.mypy]
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
// Localize documenteer.ext.lastmodified's "last modified" footer date.
|
|
2
|
+
//
|
|
3
|
+
// The footer renders the page's Git commit date as a <time> element whose
|
|
4
|
+
// datetime attribute carries the canonical UTC ISO 8601 timestamp and whose
|
|
5
|
+
// visible text is the UTC date (YYYY-MM-DD) as a no-JavaScript fallback. This
|
|
6
|
+
// script rewrites that text to the reader's own local date in a long-month
|
|
7
|
+
// style (for example "June 1, 2024"), so a UTC date that lands on a different
|
|
8
|
+
// calendar day than the reader's is shown correctly for the reader.
|
|
9
|
+
//
|
|
10
|
+
// On any parse failure or invalid date the UTC fallback text is left intact.
|
|
11
|
+
(function () {
|
|
12
|
+
'use strict';
|
|
13
|
+
|
|
14
|
+
function localize() {
|
|
15
|
+
var elements = document.querySelectorAll(
|
|
16
|
+
'time[data-documenteer-last-modified]'
|
|
17
|
+
);
|
|
18
|
+
for (var i = 0; i < elements.length; i++) {
|
|
19
|
+
var element = elements[i];
|
|
20
|
+
var iso = element.getAttribute('datetime');
|
|
21
|
+
if (!iso) {
|
|
22
|
+
continue;
|
|
23
|
+
}
|
|
24
|
+
try {
|
|
25
|
+
var date = new Date(iso);
|
|
26
|
+
if (isNaN(date.getTime())) {
|
|
27
|
+
continue;
|
|
28
|
+
}
|
|
29
|
+
element.textContent = date.toLocaleDateString(undefined, {
|
|
30
|
+
year: 'numeric',
|
|
31
|
+
month: 'long',
|
|
32
|
+
day: 'numeric',
|
|
33
|
+
});
|
|
34
|
+
} catch (error) {
|
|
35
|
+
// Leave the UTC fallback text untouched.
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
if (document.readyState === 'loading') {
|
|
41
|
+
document.addEventListener('DOMContentLoaded', localize);
|
|
42
|
+
} else {
|
|
43
|
+
localize();
|
|
44
|
+
}
|
|
45
|
+
})();
|
|
@@ -109,3 +109,25 @@ body {
|
|
|
109
109
|
.navbar-nav i {
|
|
110
110
|
font-size: var(--pst-font-size-icon);
|
|
111
111
|
}
|
|
112
|
+
|
|
113
|
+
/* "Last updated" timestamp at the bottom of the article body
|
|
114
|
+
* (documenteer.ext.lastmodified -> pydata "last-updated" component).
|
|
115
|
+
* Left-aligned, muted, with breathing room above and below so it reads as
|
|
116
|
+
* page metadata between the body and the prev/next navigation. */
|
|
117
|
+
.bd-footer-article .last-updated {
|
|
118
|
+
margin-top: 1.5rem;
|
|
119
|
+
margin-bottom: 0.5rem;
|
|
120
|
+
text-align: left;
|
|
121
|
+
font-size: 0.875em;
|
|
122
|
+
color: var(--pst-color-text-muted);
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
/* Indent the footer so the timestamp lines up with the article body text.
|
|
126
|
+
* pydata-sphinx-theme only indents the article (.bd-article) by 2rem at
|
|
127
|
+
* >=1200px, so match that breakpoint to avoid over-indenting on narrow
|
|
128
|
+
* screens, where the body has no extra indent. */
|
|
129
|
+
@media (min-width: 1200px) {
|
|
130
|
+
.bd-footer-article {
|
|
131
|
+
padding-left: 2rem;
|
|
132
|
+
}
|
|
133
|
+
}
|
|
@@ -198,6 +198,14 @@ class ThemeModel(BaseModel):
|
|
|
198
198
|
),
|
|
199
199
|
)
|
|
200
200
|
|
|
201
|
+
show_last_updated: bool = Field(
|
|
202
|
+
True,
|
|
203
|
+
description=(
|
|
204
|
+
"Show a 'Last updated' timestamp at the bottom of each page "
|
|
205
|
+
"derived from Git commit dates if True"
|
|
206
|
+
),
|
|
207
|
+
)
|
|
208
|
+
|
|
201
209
|
|
|
202
210
|
class SphinxModel(BaseModel):
|
|
203
211
|
"""Model for Sphinx configurations in documenteer.toml."""
|
|
@@ -565,3 +573,13 @@ class DocumenteerConfig:
|
|
|
565
573
|
return self.conf.sphinx.theme.header_links_before_dropdown
|
|
566
574
|
else:
|
|
567
575
|
return 5
|
|
576
|
+
|
|
577
|
+
@property
|
|
578
|
+
def show_last_updated(self) -> bool:
|
|
579
|
+
"""Whether to show a "Last updated" timestamp at the bottom of each
|
|
580
|
+
page derived from Git commit dates.
|
|
581
|
+
"""
|
|
582
|
+
if self.conf.sphinx:
|
|
583
|
+
return self.conf.sphinx.theme.show_last_updated
|
|
584
|
+
else:
|
|
585
|
+
return True
|
|
@@ -2,6 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
from __future__ import annotations
|
|
4
4
|
|
|
5
|
+
from collections.abc import Sequence
|
|
6
|
+
from datetime import datetime
|
|
5
7
|
from pathlib import Path
|
|
6
8
|
|
|
7
9
|
from git import Repo
|
|
@@ -107,6 +109,10 @@ class GitRepository:
|
|
|
107
109
|
|
|
108
110
|
def __init__(self, dirname: Path) -> None:
|
|
109
111
|
self._repo = Repo(dirname, search_parent_directories=True)
|
|
112
|
+
# Cache of the last-modified datetime for each absolute path so that
|
|
113
|
+
# shared dependencies (e.g. included files) are only resolved once per
|
|
114
|
+
# build, rather than once per referencing page.
|
|
115
|
+
self._last_modified_cache: dict[str, datetime | None] = {}
|
|
110
116
|
|
|
111
117
|
@property
|
|
112
118
|
def working_tree_dir(self) -> Path:
|
|
@@ -116,6 +122,70 @@ class GitRepository:
|
|
|
116
122
|
raise RuntimeError("Git repository is not available.")
|
|
117
123
|
return Path(path)
|
|
118
124
|
|
|
125
|
+
@property
|
|
126
|
+
def is_shallow(self) -> bool:
|
|
127
|
+
"""Whether the repository is a shallow clone.
|
|
128
|
+
|
|
129
|
+
A shallow clone (such as one produced by ``actions/checkout`` without
|
|
130
|
+
``fetch-depth: 0``) does not contain the full commit history, so
|
|
131
|
+
commit-date lookups are unreliable.
|
|
132
|
+
"""
|
|
133
|
+
result = self._repo.git.rev_parse("--is-shallow-repository")
|
|
134
|
+
return result.strip() == "true"
|
|
135
|
+
|
|
136
|
+
def compute_last_modified(
|
|
137
|
+
self, paths: Sequence[Path | str]
|
|
138
|
+
) -> datetime | None:
|
|
139
|
+
"""Compute the most-recent commit datetime across a set of paths.
|
|
140
|
+
|
|
141
|
+
Parameters
|
|
142
|
+
----------
|
|
143
|
+
paths
|
|
144
|
+
Paths to consider. Typically a page's source file together with
|
|
145
|
+
any files it pulls in via ``include``/``literalinclude``.
|
|
146
|
+
|
|
147
|
+
Returns
|
|
148
|
+
-------
|
|
149
|
+
datetime.datetime or None
|
|
150
|
+
The most recent commit datetime (timezone-aware) across all of the
|
|
151
|
+
tracked ``paths``. Paths that are untracked (e.g. new or
|
|
152
|
+
uncommitted files), or that lie outside the Git working tree, are
|
|
153
|
+
ignored. Returns `None` if none of the paths are tracked in the
|
|
154
|
+
repository.
|
|
155
|
+
"""
|
|
156
|
+
working_tree_dir = self.working_tree_dir.resolve()
|
|
157
|
+
datetimes: list[datetime] = []
|
|
158
|
+
for path in paths:
|
|
159
|
+
abs_path = Path(path).resolve()
|
|
160
|
+
|
|
161
|
+
# Defensively skip paths that aren't inside the working tree; Git
|
|
162
|
+
# cannot report history for them.
|
|
163
|
+
if not abs_path.is_relative_to(working_tree_dir):
|
|
164
|
+
continue
|
|
165
|
+
|
|
166
|
+
key = str(abs_path)
|
|
167
|
+
if key in self._last_modified_cache:
|
|
168
|
+
cached = self._last_modified_cache[key]
|
|
169
|
+
else:
|
|
170
|
+
cached = self._get_path_last_modified(abs_path)
|
|
171
|
+
self._last_modified_cache[key] = cached
|
|
172
|
+
|
|
173
|
+
if cached is not None:
|
|
174
|
+
datetimes.append(cached)
|
|
175
|
+
|
|
176
|
+
if not datetimes:
|
|
177
|
+
return None
|
|
178
|
+
return max(datetimes)
|
|
179
|
+
|
|
180
|
+
def _get_path_last_modified(self, path: Path) -> datetime | None:
|
|
181
|
+
"""Get the datetime of the most recent commit touching a single path,
|
|
182
|
+
or `None` if the path isn't tracked.
|
|
183
|
+
"""
|
|
184
|
+
commits = list(self._repo.iter_commits(paths=str(path), max_count=1))
|
|
185
|
+
if not commits:
|
|
186
|
+
return None
|
|
187
|
+
return commits[0].committed_datetime
|
|
188
|
+
|
|
119
189
|
|
|
120
190
|
def extend_excludes_for_non_index_source(
|
|
121
191
|
exclude_patterns: list[str],
|