mkdocs-webis 0.1.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.
- mkdocs_webis-0.1.0/.github/dependabot.yml +10 -0
- mkdocs_webis-0.1.0/.github/release.yml +16 -0
- mkdocs_webis-0.1.0/.github/workflows/ci.yml +207 -0
- mkdocs_webis-0.1.0/.gitignore +169 -0
- mkdocs_webis-0.1.0/LICENSE +21 -0
- mkdocs_webis-0.1.0/PKG-INFO +161 -0
- mkdocs_webis-0.1.0/README.md +129 -0
- mkdocs_webis-0.1.0/docs/citations.md +28 -0
- mkdocs_webis-0.1.0/docs/index.md +42 -0
- mkdocs_webis-0.1.0/docs/references.bib +61 -0
- mkdocs_webis-0.1.0/docs/style.md +110 -0
- mkdocs_webis-0.1.0/mkdocs.yml +69 -0
- mkdocs_webis-0.1.0/mkdocs_webis/__init__.py +11 -0
- mkdocs_webis-0.1.0/mkdocs_webis/assets/favicon.png +0 -0
- mkdocs_webis-0.1.0/mkdocs_webis/assets/webis-logo.png +0 -0
- mkdocs_webis-0.1.0/mkdocs_webis/assets/webis.css +752 -0
- mkdocs_webis-0.1.0/mkdocs_webis/bibliography.py +258 -0
- mkdocs_webis-0.1.0/mkdocs_webis/plugin.py +123 -0
- mkdocs_webis-0.1.0/mkdocs_webis/py.typed +0 -0
- mkdocs_webis-0.1.0/mkdocs_webis/templates/partials/header.html +51 -0
- mkdocs_webis-0.1.0/mkdocs_webis/templates/partials/tabs.html +1 -0
- mkdocs_webis-0.1.0/mkdocs_webis/templates/partials/webis-nav-item.html +22 -0
- mkdocs_webis-0.1.0/mkdocs_webis.egg-info/PKG-INFO +161 -0
- mkdocs_webis-0.1.0/mkdocs_webis.egg-info/SOURCES.txt +32 -0
- mkdocs_webis-0.1.0/mkdocs_webis.egg-info/dependency_links.txt +1 -0
- mkdocs_webis-0.1.0/mkdocs_webis.egg-info/entry_points.txt +2 -0
- mkdocs_webis-0.1.0/mkdocs_webis.egg-info/requires.txt +10 -0
- mkdocs_webis-0.1.0/mkdocs_webis.egg-info/scm_file_list.json +28 -0
- mkdocs_webis-0.1.0/mkdocs_webis.egg-info/scm_version.json +8 -0
- mkdocs_webis-0.1.0/mkdocs_webis.egg-info/top_level.txt +3 -0
- mkdocs_webis-0.1.0/pyproject.toml +79 -0
- mkdocs_webis-0.1.0/setup.cfg +4 -0
- mkdocs_webis-0.1.0/tests/test_bibliography.py +151 -0
- mkdocs_webis-0.1.0/tests/test_plugin.py +117 -0
|
@@ -0,0 +1,207 @@
|
|
|
1
|
+
name: CI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
|
|
6
|
+
jobs:
|
|
7
|
+
python-build:
|
|
8
|
+
name: "🏗️ Build Python wheels"
|
|
9
|
+
strategy:
|
|
10
|
+
matrix:
|
|
11
|
+
python:
|
|
12
|
+
- "3.11"
|
|
13
|
+
- "3.12"
|
|
14
|
+
- "3.13"
|
|
15
|
+
- "3.14"
|
|
16
|
+
runs-on: ubuntu-latest
|
|
17
|
+
steps:
|
|
18
|
+
- name: "📥 Check-out"
|
|
19
|
+
uses: actions/checkout@v7
|
|
20
|
+
with:
|
|
21
|
+
fetch-depth: 0
|
|
22
|
+
- name: "🧰 Install Python"
|
|
23
|
+
uses: actions/setup-python@v7
|
|
24
|
+
with:
|
|
25
|
+
python-version: ${{ matrix.python }}
|
|
26
|
+
cache: pip
|
|
27
|
+
cache-dependency-path: pyproject.toml
|
|
28
|
+
- name: "🧰 Install dependencies"
|
|
29
|
+
run: pip install build twine
|
|
30
|
+
- name: "🏗️ Build Python wheels"
|
|
31
|
+
run: python -m build
|
|
32
|
+
- name: "🧪 Check package bundles"
|
|
33
|
+
run: twine check --strict dist/*
|
|
34
|
+
- name: "📤 Upload Python wheels"
|
|
35
|
+
uses: actions/upload-artifact@v7
|
|
36
|
+
if: matrix.python == '3.14'
|
|
37
|
+
with:
|
|
38
|
+
name: wheels
|
|
39
|
+
path: dist
|
|
40
|
+
python-code-check:
|
|
41
|
+
name: "🔍 Check Python code"
|
|
42
|
+
strategy:
|
|
43
|
+
matrix:
|
|
44
|
+
python:
|
|
45
|
+
- "3.11"
|
|
46
|
+
- "3.12"
|
|
47
|
+
- "3.13"
|
|
48
|
+
- "3.14"
|
|
49
|
+
runs-on: ubuntu-latest
|
|
50
|
+
steps:
|
|
51
|
+
- name: "📥 Check-out"
|
|
52
|
+
uses: actions/checkout@v7
|
|
53
|
+
- name: "🧰 Install Python"
|
|
54
|
+
uses: actions/setup-python@v7
|
|
55
|
+
with:
|
|
56
|
+
python-version: ${{ matrix.python }}
|
|
57
|
+
cache: pip
|
|
58
|
+
cache-dependency-path: pyproject.toml
|
|
59
|
+
- name: "🧰 Install dependencies"
|
|
60
|
+
run: pip install .[tests]
|
|
61
|
+
- name: "🔍 Check Python code"
|
|
62
|
+
run: ruff check .
|
|
63
|
+
python-typing:
|
|
64
|
+
name: "🔍 Check Python static typing"
|
|
65
|
+
strategy:
|
|
66
|
+
matrix:
|
|
67
|
+
python:
|
|
68
|
+
- "3.11"
|
|
69
|
+
- "3.12"
|
|
70
|
+
- "3.13"
|
|
71
|
+
- "3.14"
|
|
72
|
+
runs-on: ubuntu-latest
|
|
73
|
+
steps:
|
|
74
|
+
- name: "📥 Check-out"
|
|
75
|
+
uses: actions/checkout@v7
|
|
76
|
+
- name: "🧰 Install Python"
|
|
77
|
+
uses: actions/setup-python@v7
|
|
78
|
+
with:
|
|
79
|
+
python-version: ${{ matrix.python }}
|
|
80
|
+
cache: pip
|
|
81
|
+
cache-dependency-path: pyproject.toml
|
|
82
|
+
- name: "🧰 Install dependencies"
|
|
83
|
+
run: pip install .[tests]
|
|
84
|
+
- name: "🔍 Check Python static typing"
|
|
85
|
+
run: mypy .
|
|
86
|
+
python-test:
|
|
87
|
+
name: "🧪 Test Python code"
|
|
88
|
+
strategy:
|
|
89
|
+
matrix:
|
|
90
|
+
python:
|
|
91
|
+
- "3.11"
|
|
92
|
+
- "3.12"
|
|
93
|
+
- "3.13"
|
|
94
|
+
- "3.14"
|
|
95
|
+
runs-on: ubuntu-latest
|
|
96
|
+
steps:
|
|
97
|
+
- name: "📥 Check-out"
|
|
98
|
+
uses: actions/checkout@v7
|
|
99
|
+
- name: "🧰 Install Python"
|
|
100
|
+
uses: actions/setup-python@v7
|
|
101
|
+
with:
|
|
102
|
+
python-version: ${{ matrix.python }}
|
|
103
|
+
cache: pip
|
|
104
|
+
cache-dependency-path: pyproject.toml
|
|
105
|
+
- name: "🧰 Install dependencies"
|
|
106
|
+
run: pip install .[tests]
|
|
107
|
+
- name: "🧪 Test Python code"
|
|
108
|
+
run: pytest --cov --cov-report=xml .
|
|
109
|
+
- name: "📤 Upload coverage to Codecov"
|
|
110
|
+
uses: codecov/codecov-action@v7
|
|
111
|
+
if: matrix.python == '3.14'
|
|
112
|
+
with:
|
|
113
|
+
token: ${{ secrets.CODECOV_TOKEN }}
|
|
114
|
+
docs-build:
|
|
115
|
+
name: "📖 Build documentation"
|
|
116
|
+
runs-on: ubuntu-latest
|
|
117
|
+
steps:
|
|
118
|
+
- name: "📥 Check-out"
|
|
119
|
+
uses: actions/checkout@v7
|
|
120
|
+
- name: "🧰 Install Python"
|
|
121
|
+
uses: actions/setup-python@v7
|
|
122
|
+
with:
|
|
123
|
+
python-version: "3.14"
|
|
124
|
+
cache: pip
|
|
125
|
+
cache-dependency-path: pyproject.toml
|
|
126
|
+
- name: "🧰 Install dependencies"
|
|
127
|
+
run: pip install .
|
|
128
|
+
- name: "📖 Build documentation"
|
|
129
|
+
run: mkdocs build --strict
|
|
130
|
+
env:
|
|
131
|
+
DISABLE_MKDOCS_2_WARNING: "true"
|
|
132
|
+
- name: "📤 Upload documentation"
|
|
133
|
+
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
|
|
134
|
+
uses: actions/upload-pages-artifact@v5
|
|
135
|
+
with:
|
|
136
|
+
path: site
|
|
137
|
+
docs-deploy:
|
|
138
|
+
name: "🚀 Deploy documentation to GitHub Pages"
|
|
139
|
+
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
|
|
140
|
+
needs:
|
|
141
|
+
- docs-build
|
|
142
|
+
runs-on: ubuntu-latest
|
|
143
|
+
permissions:
|
|
144
|
+
pages: write
|
|
145
|
+
id-token: write
|
|
146
|
+
environment:
|
|
147
|
+
name: github-pages
|
|
148
|
+
url: ${{ steps.deployment.outputs.page_url }}
|
|
149
|
+
concurrency:
|
|
150
|
+
group: github-pages
|
|
151
|
+
cancel-in-progress: false
|
|
152
|
+
steps:
|
|
153
|
+
- name: "🚀 Deploy to GitHub Pages"
|
|
154
|
+
id: deployment
|
|
155
|
+
uses: actions/deploy-pages@v5
|
|
156
|
+
python-publish:
|
|
157
|
+
name: "🚀 Publish Python wheels"
|
|
158
|
+
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
|
|
159
|
+
needs:
|
|
160
|
+
- python-build
|
|
161
|
+
- python-code-check
|
|
162
|
+
- python-typing
|
|
163
|
+
- python-test
|
|
164
|
+
- docs-build
|
|
165
|
+
runs-on: ubuntu-latest
|
|
166
|
+
permissions:
|
|
167
|
+
id-token: write
|
|
168
|
+
steps:
|
|
169
|
+
- name: "📥 Check-out"
|
|
170
|
+
uses: actions/checkout@v7
|
|
171
|
+
- name: "📥 Download Python wheels"
|
|
172
|
+
uses: actions/download-artifact@v8
|
|
173
|
+
with:
|
|
174
|
+
name: wheels
|
|
175
|
+
path: dist
|
|
176
|
+
- name: "🚀 Publish Python wheels"
|
|
177
|
+
uses: pypa/gh-action-pypi-publish@release/v1
|
|
178
|
+
github-release:
|
|
179
|
+
name: "🚀 Create GitHub release"
|
|
180
|
+
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
|
|
181
|
+
needs:
|
|
182
|
+
- python-build
|
|
183
|
+
- python-code-check
|
|
184
|
+
- python-typing
|
|
185
|
+
- python-test
|
|
186
|
+
- docs-build
|
|
187
|
+
- python-publish
|
|
188
|
+
permissions:
|
|
189
|
+
contents: write
|
|
190
|
+
runs-on: ubuntu-latest
|
|
191
|
+
steps:
|
|
192
|
+
- name: "📥 Check-out"
|
|
193
|
+
uses: actions/checkout@v7
|
|
194
|
+
- name: "📥 Download Python wheels"
|
|
195
|
+
uses: actions/download-artifact@v8
|
|
196
|
+
with:
|
|
197
|
+
name: wheels
|
|
198
|
+
path: dist
|
|
199
|
+
- name: "🚀 Create GitHub release"
|
|
200
|
+
uses: softprops/action-gh-release@v3
|
|
201
|
+
with:
|
|
202
|
+
name: Release ${{ github.ref_name }}
|
|
203
|
+
files: dist/*
|
|
204
|
+
fail_on_unmatched_files: true
|
|
205
|
+
draft: false
|
|
206
|
+
prerelease: false
|
|
207
|
+
generate_release_notes: true
|
|
@@ -0,0 +1,169 @@
|
|
|
1
|
+
# Created by https://www.toptal.com/developers/gitignore/api/python,visualstudiocode,intellij
|
|
2
|
+
# Edit at https://www.toptal.com/developers/gitignore?templates=python,visualstudiocode,intellij
|
|
3
|
+
|
|
4
|
+
### Intellij ###
|
|
5
|
+
.idea
|
|
6
|
+
*.iml
|
|
7
|
+
|
|
8
|
+
### Python ###
|
|
9
|
+
# Byte-compiled / optimized / DLL files
|
|
10
|
+
__pycache__/
|
|
11
|
+
*.py[cod]
|
|
12
|
+
*$py.class
|
|
13
|
+
|
|
14
|
+
# C extensions
|
|
15
|
+
*.so
|
|
16
|
+
|
|
17
|
+
# Distribution / packaging
|
|
18
|
+
.Python
|
|
19
|
+
build/
|
|
20
|
+
develop-eggs/
|
|
21
|
+
dist/
|
|
22
|
+
downloads/
|
|
23
|
+
eggs/
|
|
24
|
+
.eggs/
|
|
25
|
+
lib/
|
|
26
|
+
lib64/
|
|
27
|
+
parts/
|
|
28
|
+
sdist/
|
|
29
|
+
var/
|
|
30
|
+
wheels/
|
|
31
|
+
share/python-wheels/
|
|
32
|
+
*.egg-info/
|
|
33
|
+
.installed.cfg
|
|
34
|
+
*.egg
|
|
35
|
+
MANIFEST
|
|
36
|
+
|
|
37
|
+
# PyInstaller
|
|
38
|
+
# Usually these files are written by a python script from a template
|
|
39
|
+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
|
|
40
|
+
*.manifest
|
|
41
|
+
*.spec
|
|
42
|
+
|
|
43
|
+
# Installer logs
|
|
44
|
+
pip-log.txt
|
|
45
|
+
pip-delete-this-directory.txt
|
|
46
|
+
|
|
47
|
+
# Unit test / coverage reports
|
|
48
|
+
htmlcov/
|
|
49
|
+
.tox/
|
|
50
|
+
.nox/
|
|
51
|
+
.coverage
|
|
52
|
+
.coverage.*
|
|
53
|
+
.cache
|
|
54
|
+
nosetests.xml
|
|
55
|
+
coverage.xml
|
|
56
|
+
*.cover
|
|
57
|
+
*.py,cover
|
|
58
|
+
.hypothesis/
|
|
59
|
+
.pytest_cache/
|
|
60
|
+
cover/
|
|
61
|
+
|
|
62
|
+
# Translations
|
|
63
|
+
*.mo
|
|
64
|
+
*.pot
|
|
65
|
+
|
|
66
|
+
# Django stuff:
|
|
67
|
+
*.log
|
|
68
|
+
local_settings.py
|
|
69
|
+
db.sqlite3
|
|
70
|
+
db.sqlite3-journal
|
|
71
|
+
|
|
72
|
+
# Flask stuff:
|
|
73
|
+
instance/
|
|
74
|
+
.webassets-cache
|
|
75
|
+
|
|
76
|
+
# Scrapy stuff:
|
|
77
|
+
.scrapy
|
|
78
|
+
|
|
79
|
+
# Sphinx documentation
|
|
80
|
+
docs/_build/
|
|
81
|
+
|
|
82
|
+
# PyBuilder
|
|
83
|
+
.pybuilder/
|
|
84
|
+
target/
|
|
85
|
+
|
|
86
|
+
# Jupyter Notebook
|
|
87
|
+
.ipynb_checkpoints
|
|
88
|
+
|
|
89
|
+
# IPython
|
|
90
|
+
profile_default/
|
|
91
|
+
ipython_config.py
|
|
92
|
+
|
|
93
|
+
# pyenv
|
|
94
|
+
# For a library or package, you might want to ignore these files since the code is
|
|
95
|
+
# intended to run in multiple environments; otherwise, check them in:
|
|
96
|
+
# .python-version
|
|
97
|
+
|
|
98
|
+
# pipenv
|
|
99
|
+
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
|
|
100
|
+
# However, in case of collaboration, if having platform-specific dependencies or dependencies
|
|
101
|
+
# having no cross-platform support, pipenv may install dependencies that don't work, or not
|
|
102
|
+
# install all needed dependencies.
|
|
103
|
+
#Pipfile.lock
|
|
104
|
+
|
|
105
|
+
# PEP 582; used by e.g. github.com/David-OConnor/pyflow
|
|
106
|
+
__pypackages__/
|
|
107
|
+
|
|
108
|
+
# Celery stuff
|
|
109
|
+
celerybeat-schedule
|
|
110
|
+
celerybeat.pid
|
|
111
|
+
|
|
112
|
+
# SageMath parsed files
|
|
113
|
+
*.sage.py
|
|
114
|
+
|
|
115
|
+
# Environments
|
|
116
|
+
.env
|
|
117
|
+
.venv
|
|
118
|
+
env/
|
|
119
|
+
venv/
|
|
120
|
+
ENV/
|
|
121
|
+
env.bak/
|
|
122
|
+
venv.bak/
|
|
123
|
+
|
|
124
|
+
# Spyder project settings
|
|
125
|
+
.spyderproject
|
|
126
|
+
.spyproject
|
|
127
|
+
|
|
128
|
+
# Rope project settings
|
|
129
|
+
.ropeproject
|
|
130
|
+
|
|
131
|
+
# mkdocs documentation
|
|
132
|
+
/site
|
|
133
|
+
|
|
134
|
+
# mypy
|
|
135
|
+
.mypy_cache/
|
|
136
|
+
.dmypy.json
|
|
137
|
+
dmypy.json
|
|
138
|
+
|
|
139
|
+
# Pyre type checker
|
|
140
|
+
.pyre/
|
|
141
|
+
|
|
142
|
+
# pytype static type analyzer
|
|
143
|
+
.pytype/
|
|
144
|
+
|
|
145
|
+
# Cython debug symbols
|
|
146
|
+
cython_debug/
|
|
147
|
+
|
|
148
|
+
### VisualStudioCode ###
|
|
149
|
+
.vscode/*
|
|
150
|
+
!.vscode/settings.json
|
|
151
|
+
!.vscode/tasks.json
|
|
152
|
+
!.vscode/launch.json
|
|
153
|
+
!.vscode/extensions.json
|
|
154
|
+
*.code-workspace
|
|
155
|
+
|
|
156
|
+
# Local History for Visual Studio Code
|
|
157
|
+
.history/
|
|
158
|
+
|
|
159
|
+
### VisualStudioCode Patch ###
|
|
160
|
+
# Ignore all local history of files
|
|
161
|
+
.history
|
|
162
|
+
.ionide
|
|
163
|
+
|
|
164
|
+
# Support for Project snippet scope
|
|
165
|
+
!.vscode/*.code-snippets
|
|
166
|
+
|
|
167
|
+
# End of https://www.toptal.com/developers/gitignore/api/python,visualstudiocode,intellij
|
|
168
|
+
|
|
169
|
+
venv-*/
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Jan Heinrich Merker
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
@@ -0,0 +1,161 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: mkdocs-webis
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: Webis style and BibTeX citations for MkDocs Material.
|
|
5
|
+
Author-email: Jan Heinrich Merker <heinrich.merker@uni-jena.de>
|
|
6
|
+
License-Expression: MIT
|
|
7
|
+
Project-URL: Homepage, https://github.com/webis-de/mkdocs-webis
|
|
8
|
+
Project-URL: Bug Tracker, https://github.com/webis-de/mkdocs-webis/issues
|
|
9
|
+
Classifier: Programming Language :: Python :: 3
|
|
10
|
+
Classifier: Programming Language :: Python :: 3 :: Only
|
|
11
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
12
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
13
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
14
|
+
Classifier: Programming Language :: Python :: 3.14
|
|
15
|
+
Classifier: Operating System :: OS Independent
|
|
16
|
+
Classifier: Framework :: MkDocs
|
|
17
|
+
Classifier: Intended Audience :: Science/Research
|
|
18
|
+
Classifier: Topic :: Documentation
|
|
19
|
+
Requires-Python: >=3.11
|
|
20
|
+
Description-Content-Type: text/markdown
|
|
21
|
+
License-File: LICENSE
|
|
22
|
+
Requires-Dist: mkdocs~=1.6
|
|
23
|
+
Requires-Dist: mkdocs-material~=9.6
|
|
24
|
+
Requires-Dist: bibtexparser~=2.0
|
|
25
|
+
Requires-Dist: pylatexenc~=2.10
|
|
26
|
+
Provides-Extra: tests
|
|
27
|
+
Requires-Dist: mypy<3.0,>=1.13; extra == "tests"
|
|
28
|
+
Requires-Dist: pytest<10.0,>=8.3; extra == "tests"
|
|
29
|
+
Requires-Dist: pytest-cov<8.0,>=6.3; extra == "tests"
|
|
30
|
+
Requires-Dist: ruff<0.18.0,>=0.12.7; extra == "tests"
|
|
31
|
+
Dynamic: license-file
|
|
32
|
+
|
|
33
|
+
<!-- markdownlint-disable MD041 -->
|
|
34
|
+
|
|
35
|
+
[](https://pypi.org/project/mkdocs-webis/)
|
|
36
|
+
[](https://github.com/webis-de/mkdocs-webis/actions/workflows/ci.yml)
|
|
37
|
+
[](https://codecov.io/github/webis-de/mkdocs-webis/)
|
|
38
|
+
[](https://pypi.org/project/mkdocs-webis/)
|
|
39
|
+
[](https://github.com/webis-de/mkdocs-webis/issues)
|
|
40
|
+
[](https://github.com/webis-de/mkdocs-webis/commits)
|
|
41
|
+
[](https://pypi.org/project/mkdocs-webis/)
|
|
42
|
+
[](LICENSE)
|
|
43
|
+
|
|
44
|
+
# 📘 mkdocs-webis
|
|
45
|
+
|
|
46
|
+
Webis style and BibTeX citations for [MkDocs Material](https://squidfunk.github.io/mkdocs-material/).
|
|
47
|
+
|
|
48
|
+
This MkDocs plugin...
|
|
49
|
+
|
|
50
|
+
- ... styles your documentation like the [Webis homepage](https://webis.de/) (a dark gray navigation bar with the Webis logo, the "Product Sans" and "Noto Sans" fonts, plain headings, blue links and buttons, flat tables, and a light gray footer),
|
|
51
|
+
- ... lets you cite references from a BibTeX file with `[@key]` or `[@key1, @key2]`, rendered as gray author–year citations like "[Fang et al., 2004]", and appends a list of the cited references (including their BibTeX) to each page.
|
|
52
|
+
|
|
53
|
+
The [documentation](https://webis-de.github.io/mkdocs-webis/) is rendered with the plugin itself, so it doubles as a demo.
|
|
54
|
+
|
|
55
|
+
## Installation
|
|
56
|
+
|
|
57
|
+
Install the package from PyPI:
|
|
58
|
+
|
|
59
|
+
```shell
|
|
60
|
+
pip install mkdocs-webis
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
## Usage
|
|
64
|
+
|
|
65
|
+
Enable the plugin in your `mkdocs.yml` (together with the [Material](https://squidfunk.github.io/mkdocs-material/) theme):
|
|
66
|
+
|
|
67
|
+
```yaml
|
|
68
|
+
theme:
|
|
69
|
+
name: material
|
|
70
|
+
|
|
71
|
+
plugins:
|
|
72
|
+
- webis:
|
|
73
|
+
# Optional: BibTeX file in your docs directory.
|
|
74
|
+
bibliography: references.bib
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
### Citations
|
|
78
|
+
|
|
79
|
+
With a `bibliography` configured, cite references by their BibTeX keys:
|
|
80
|
+
|
|
81
|
+
```markdown
|
|
82
|
+
Axioms are formal constraints on retrieval models [@fang2004formal].
|
|
83
|
+
Some studies use axioms for re-ranking [@hagen2016axiomatic, @bondarenko2022axiomatic].
|
|
84
|
+
```
|
|
85
|
+
|
|
86
|
+
Citations are rendered as gray author–year links in brackets (e.g., "[Fang et al., 2004]" or "[Hagen et al., 2016; Bondarenko et al., 2022]"), like on the Webis slides.
|
|
87
|
+
They link to a "References" section at the bottom of the same page, which lists all references cited on that page.
|
|
88
|
+
Multiple keys are separated by commas or semicolons.
|
|
89
|
+
|
|
90
|
+
We recommend copying BibTeX entries from [DBLP](https://dblp.org/).
|
|
91
|
+
|
|
92
|
+
### Style Elements
|
|
93
|
+
|
|
94
|
+
Besides styling the standard Material elements, the stylesheet provides a few CSS classes:
|
|
95
|
+
|
|
96
|
+
```markdown
|
|
97
|
+
# Page Title
|
|
98
|
+
|
|
99
|
+
<p class="subtitle">A gray subtitle below the page title.</p>
|
|
100
|
+
|
|
101
|
+
<span class="badge">TFC1</span> — a small label, e.g., for names or acronyms.
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
The colors of webis.de are available as CSS variables (e.g., `var(--webis-blue)`, `var(--webis-red)`) for your own stylesheets.
|
|
105
|
+
See the [style elements](https://webis-de.github.io/mkdocs-webis/style/) for how all elements look.
|
|
106
|
+
|
|
107
|
+
## Development
|
|
108
|
+
|
|
109
|
+
To build this package and contribute to its development you need to install the `build`, `setuptools` and `wheel` packages:
|
|
110
|
+
|
|
111
|
+
```shell
|
|
112
|
+
pip install build setuptools wheel
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
(On most systems, these packages are already pre-installed.)
|
|
116
|
+
|
|
117
|
+
### Development installation
|
|
118
|
+
|
|
119
|
+
Install package and test dependencies:
|
|
120
|
+
|
|
121
|
+
```shell
|
|
122
|
+
pip install -e .[tests]
|
|
123
|
+
```
|
|
124
|
+
|
|
125
|
+
### Testing
|
|
126
|
+
|
|
127
|
+
Verify your changes against the test suite to verify.
|
|
128
|
+
|
|
129
|
+
```shell
|
|
130
|
+
ruff check . # Code format, LINT, and security
|
|
131
|
+
mypy . # Static typing
|
|
132
|
+
pytest . # Unit tests
|
|
133
|
+
```
|
|
134
|
+
|
|
135
|
+
Please also add tests for your newly developed code.
|
|
136
|
+
|
|
137
|
+
### Documentation and demo
|
|
138
|
+
|
|
139
|
+
The documentation in [`docs/`](docs/) uses the plugin itself, including a [page with all style elements](docs/style.md) and [citations](docs/citations.md).
|
|
140
|
+
Preview it locally to check changes to the style or the citations:
|
|
141
|
+
|
|
142
|
+
```shell
|
|
143
|
+
mkdocs serve
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
### Build wheels
|
|
147
|
+
|
|
148
|
+
Wheels for this package can be built with:
|
|
149
|
+
|
|
150
|
+
```shell
|
|
151
|
+
python -m build
|
|
152
|
+
```
|
|
153
|
+
|
|
154
|
+
## Support
|
|
155
|
+
|
|
156
|
+
If you have any problems using this package, please file an [issue](https://github.com/webis-de/mkdocs-webis/issues/new).
|
|
157
|
+
We're happy to help!
|
|
158
|
+
|
|
159
|
+
## License
|
|
160
|
+
|
|
161
|
+
This repository is released under the [MIT license](LICENSE).
|