aboutsummaryrefslogtreecommitdiff
path: root/CONTRIBUTING.md
diff options
context:
space:
mode:
authorJongwook Choi <wookayin@gmail.com>2024-01-28 17:22:39 -0500
committerGitHub <noreply@github.com>2024-01-28 14:22:39 -0800
commit01e82eba209a96f932d3497e580ab0ca749efafa (patch)
tree51e434eb3fa50a319950d485454d42c6dd3a89c1 /CONTRIBUTING.md
parent47cd532bf15d81c913e2c29b4c9a14c3654f85d2 (diff)
downloadrneovim-01e82eba209a96f932d3497e580ab0ca749efafa.tar.gz
rneovim-01e82eba209a96f932d3497e580ab0ca749efafa.tar.bz2
rneovim-01e82eba209a96f932d3497e580ab0ca749efafa.zip
build(docs): separate lint job to validate vimdoc #27227
Summary: Separate the lint job (`make lintdoc`) to validate runtime/doc, it is no longer as a part of functionaltest (help_spec). Build (cmake) and CI: - `make lintdoc`: validate vimdoc files and test-generate HTML docs. CI will run this as a part of the "docs" workflow. - `scripts/lintdoc.lua` is added as an entry point (executable script) for validating vimdoc files. scripts/gen_help_html.lua: - Move the tests for validating docs and generating HTMLs from `help_spec.lua` to `gen_help_html`. Added: - `gen_help_html.run_validate()`. - `gen_help_html.test_gen()`. - Do not hard-code `help_dir` to `build/runtime/doc`, but resolve from `$VIMRUNTIME`. Therefore, the `make lintdoc` job will check doc files on `./runtime/doc`, not on `./build/runtime/doc`. - Add type annotations for gen_help_html.
Diffstat (limited to 'CONTRIBUTING.md')
-rw-r--r--CONTRIBUTING.md8
1 files changed, 8 insertions, 0 deletions
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index ef83c22155..5704547689 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -265,6 +265,12 @@ Many `:help` docs are autogenerated from (C or Lua) docstrings. To generate the
make doc
```
+To validate the documentation files, run:
+
+```bash
+make lintdoc
+```
+
If you need to modify or debug the documentation flow, these are the main files:
- `./scripts/gen_vimdoc.py`:
Main doc generator. Drives doxygen to generate xml files, and scrapes those
@@ -282,6 +288,8 @@ If you need to modify or debug the documentation flow, these are the main files:
src/nvim/options.lua => runtime/doc/options.txt
```
+- `./scripts/lintdoc.lua`: Validation and linting of documentation files.
+
### Lua docstrings
Use [LuaLS] annotations in Lua docstrings to annotate parameter types, return