docs(sphinx-lint): Add sphinx-lint to pre-commit

Sphinx-lint helps in linting simple formatting issues with virtually
no false positives, such as trailing spaces, missing final newlines,
presence of tabs, absence of spaces and backticks around roles, etc.
This commit is contained in:
kirill.chalov 2024-01-19 13:44:36 +08:00
parent 22a053f1fc
commit 0181f8cc88

View File

@ -225,3 +225,9 @@ repos:
hooks:
- id: validate-sbom-manifest
stages: [post-commit]
- repo: https://github.com/sphinx-contrib/sphinx-lint
rev: v0.9.1
hooks:
- id: 'sphinx-lint'
name: Lint rST files in docs folder using Sphinx Lint
files: ^(docs/en|docs/zh_CN)/.*\.(rst|inc)$