summaryrefslogtreecommitdiffstatshomepage
path: root/scripts/vim-patch.sh
diff options
context:
space:
mode:
authorYochem van Rosmalen <git@yochem.nl>2025-11-18 21:35:22 +0100
committerGitHub <noreply@github.com>2025-11-18 12:35:22 -0800
commita468bc573d094612e8d9d5b8adb97dd7ada3ccc1 (patch)
tree1fe8a076256ae5ab4e19d889d6dd864d87e6d272 /scripts/vim-patch.sh
parent098da1fc2c9ba65adb9c2f7ecb76b26f6e6b0383 (diff)
ci: check URL reachability #35593
Problem: scripts/check_urls.vim manually matches urls in the help pages and then synchronously checks them via curl/wget/powershell. This is extremely slow (~5 minutes for Nvims runtime on my machine) and prone to errors in how the urls are matched. Solution: - Use Tree-sitter to find the urls in the help pages and `vim.net.request` to check the responses. - Add a `lintdocurls` build task and check it in CI (every Friday). - Reopens a dedicated issue if it finds unreachable URLs. - Drop the old check_urls.vim script.
Diffstat (limited to 'scripts/vim-patch.sh')
-rwxr-xr-xscripts/vim-patch.sh6
1 files changed, 1 insertions, 5 deletions
diff --git a/scripts/vim-patch.sh b/scripts/vim-patch.sh
index eda530e10a..2cef123c93 100755
--- a/scripts/vim-patch.sh
+++ b/scripts/vim-patch.sh
@@ -208,7 +208,7 @@ preprocess_patch() {
2>/dev/null $nvim --cmd 'set dir=/tmp' +'g@^diff --git [ab]/runtime/\<\%('"${na_rt}"'\)\>@exe "norm! d/\\v(^diff)|%$\r"' +w +q "$file"
# Remove unwanted Vim doc files.
- local na_doc='channel\.txt\|if_cscop\.txt\|netbeans\.txt\|os_\w\+\.txt\|print\.txt\|term\.txt\|testing\.txt\|todo\.txt\|vim9\.txt\|tags'
+ local na_doc='channel\.txt\|if_cscop\.txt\|netbeans\.txt\|os_\w\+\.txt\|print\.txt\|term\.txt\|testing\.txt\|todo\.txt\|vim9\.txt\|tags\|test_urls\.vim'
2>/dev/null $nvim --cmd 'set dir=/tmp' +'g@^diff --git [ab]/runtime/doc/\<\%('"${na_doc}"'\)\>@exe "norm! d/\\v(^diff)|%$\r"' +w +q "$file"
# Remove "Last change ..." changes in doc files.
@@ -327,10 +327,6 @@ preprocess_patch() {
LC_ALL=C sed -Ee 's/( [ab]\/runtime\/doc)\/sponsor\.txt/\1\/intro.txt/g' \
"$file" > "$file".tmp && mv "$file".tmp "$file"
- # Rename test_urls.vim to check_urls.vim
- LC_ALL=C sed -Ee 's/( [ab])\/runtime\/doc\/test(_urls\.vim)/\1\/scripts\/check\2/g' \
- "$file" > "$file".tmp && mv "$file".tmp "$file"
-
# Rename path to check_colors.vim
LC_ALL=C sed -Ee 's/( [ab]\/runtime)\/colors\/(tools\/check_colors\.vim)/\1\/\2/g' \
"$file" > "$file".tmp && mv "$file".tmp "$file"