Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions .github/workflows/linting.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,25 @@ jobs:
with:
globs: "**/*.md"

lint-rst:
name: "reStructuredText"
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.x"
- name: Install rstcheck
run: |
python -m pip install --upgrade pip
pip install rstcheck
- name: Run rstcheck
run: |
rstcheck --config .rstcheck.cfg --log-level INFO --recursive docs

spelling:
name: "Spelling"
runs-on: ubuntu-latest
Expand Down
51 changes: 51 additions & 0 deletions .rstcheck.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
[rstcheck]
# Ignore Sphinx-specific roles that are not part of standard RST
ignore_roles =
meth,
class,
ref,
doc,
attr,
mod,
func,
data,
const,
exc,
obj,
any,
py:class,
py:meth,
py:func,
py:mod,
py:attr,
py:exc,
py:obj,
py:data

# Ignore Sphinx-specific directives
ignore_directives =
automodule,
autoclass,
autofunction,
autodata,
toctree,
literalinclude,
code-block,
note,
warning,
versionadded,
versionchanged,
deprecated,
seealso,
rubric,
centered,
hlist,
glossary,
productionlist,
include

# Ignore common informational messages
ignore_messages = (Hyperlink target "[^"]*" is not referenced\.$)

# Report level: ERROR, WARNING, INFO
report_level = WARNING
Loading