diff options
| author | Justin M. Keyes <justinkz@gmail.com> | 2025-04-22 05:44:50 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-04-22 05:44:50 -0700 |
| commit | d3458965499eec45d87685d6a423b99ac182e385 (patch) | |
| tree | e7563a6837744d02974c180588796a9d1f3f6f8d /.github | |
| parent | docs: update configs.md (diff) | |
| download | nvim-lspconfig-d3458965499eec45d87685d6a423b99ac182e385.tar nvim-lspconfig-d3458965499eec45d87685d6a423b99ac182e385.tar.gz nvim-lspconfig-d3458965499eec45d87685d6a423b99ac182e385.tar.bz2 nvim-lspconfig-d3458965499eec45d87685d6a423b99ac182e385.tar.lz nvim-lspconfig-d3458965499eec45d87685d6a423b99ac182e385.tar.xz nvim-lspconfig-d3458965499eec45d87685d6a423b99ac182e385.tar.zst nvim-lspconfig-d3458965499eec45d87685d6a423b99ac182e385.zip | |
ci(lint): check `@brief` docstring placement #3762
Diffstat (limited to '.github')
| -rw-r--r-- | .github/ci/lint.sh | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/.github/ci/lint.sh b/.github/ci/lint.sh index 38ea57eb..ccd23b5b 100644 --- a/.github/ci/lint.sh +++ b/.github/ci/lint.sh @@ -17,6 +17,15 @@ _check_cmd_buflocal() { fi } +# Check that "@brief" docstring is the first line of each "lsp/*.lua" config. +_check_brief_placement() { + if find ./lsp -type f -name "*.lua" -exec awk 'NR==1 && !/brief/{print FILENAME}' {} \; | grep --color=never '.' ; then + echo + echo '`@brief` docstring must be at the top of the config source file' + exit 1 + fi +} + # Enforce "Lsp" prefix on all user commands. _check_lsp_cmd_prefix() { local exclude='tinymist' @@ -58,6 +67,7 @@ _check_deprecated_utils() { } _check_cmd_buflocal +_check_brief_placement _check_lsp_cmd_prefix _check_exec_cmd _check_deprecated_utils |
