lintdoc.lua (690B)
1 #!/usr/bin/env -S nvim -l 2 3 -- Validate vimdoc files on $VIMRUNTIME/doc, and test generating HTML docs. 4 -- Checks for duplicate/missing tags, parse errors, and invalid links/urls/spellings. 5 -- See also `make lintdoc`. 6 -- 7 -- Usage: 8 -- $ nvim -l scripts/lintdoc.lua 9 -- $ make lintdoc 10 11 print('Running lintdoc ...') 12 13 -- gen_help_html.lua requires helptags to be generated in $VIMRUNTIME/doc. 14 -- :helptags also checks for duplicate tags. 15 -- 🤢 Load netrw so its tags are generated by :helptags. 16 vim.cmd [[ packadd netrw ]] 17 vim.cmd [[ helptags ALL ]] 18 19 require('src.gen.gen_help_html').run_validate(nil, _G.arg[1] ~= nil) 20 require('src.gen.gen_help_html').test_gen() 21 22 print('lintdoc PASSED.')