summaryrefslogtreecommitdiff
path: root/.github
diff options
context:
space:
mode:
authorHugo Locurcio <hugo.locurcio@hugo.pro>2022-02-14 14:18:53 +0100
committerHugo Locurcio <hugo.locurcio@hugo.pro>2022-02-15 00:03:31 +0100
commitb68dd2e1894450dd69ffddf05a45c40e6c01a36a (patch)
treea08d5005f4b46dfa2fe9180250541eb6851ee905 /.github
parent6e73aa0497b9cfc1c28863e655991106e677e69c (diff)
Add an XML schema for documentation
This makes it easier to spot syntax errors when editing the class reference. The schema is referenced locally so validation can still work offline. Each class XML's schema conformance is also checked on GitHub Actions.
Diffstat (limited to '.github')
-rw-r--r--.github/workflows/static_checks.yml6
1 files changed, 5 insertions, 1 deletions
diff --git a/.github/workflows/static_checks.yml b/.github/workflows/static_checks.yml
index 1f8888885a..724bebbd13 100644
--- a/.github/workflows/static_checks.yml
+++ b/.github/workflows/static_checks.yml
@@ -24,7 +24,7 @@ jobs:
- name: Install dependencies
run: |
- sudo apt-get install -qq dos2unix recode clang-format-13
+ sudo apt-get install -qq dos2unix recode clang-format-13 libxml2-utils
sudo update-alternatives --remove-all clang-format
sudo update-alternatives --install /usr/bin/clang-format clang-format /usr/bin/clang-format-13 100
sudo pip3 install black==21.10b0 pygments
@@ -48,6 +48,10 @@ jobs:
npm run lint
npm run docs -- -d dry-run
+ - name: Class reference schema checks
+ run: |
+ xmllint --noout --schema doc/class.xsd doc/classes/*.xml modules/*/doc_classes/*.xml
+
- name: Documentation checks
run: |
doc/tools/make_rst.py --dry-run doc/classes modules