aboutsummaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/bump_deps.lua2
-rw-r--r--scripts/gen_help_html.lua23
-rw-r--r--scripts/genvimvim.lua6
3 files changed, 16 insertions, 15 deletions
diff --git a/scripts/bump_deps.lua b/scripts/bump_deps.lua
index 1873c3cd0d..f980e800cf 100755
--- a/scripts/bump_deps.lua
+++ b/scripts/bump_deps.lua
@@ -54,7 +54,7 @@ local function run_die(cmd, err_msg)
end
local function require_executable(cmd)
- local cmd_path = run_die({ 'command', '-v', cmd }, cmd .. ' not found!')
+ local cmd_path = run_die({ 'sh', '-c', 'command -v ' .. cmd }, cmd .. ' not found!')
run_die({ 'test', '-x', cmd_path }, cmd .. ' is not executable')
end
diff --git a/scripts/gen_help_html.lua b/scripts/gen_help_html.lua
index fa7c14eaa3..2563f2f410 100644
--- a/scripts/gen_help_html.lua
+++ b/scripts/gen_help_html.lua
@@ -60,19 +60,18 @@ local exclude_invalid = {
["'previewpopup'"] = "quickref.txt",
["'pvp'"] = "quickref.txt",
["'string'"] = "eval.txt",
- Query = "treesitter.txt",
- ["eq?"] = "treesitter.txt",
- ["lsp-request"] = "lsp.txt",
- matchit = "vim_diff.txt",
- ["matchit.txt"] = "help.txt",
+ Query = 'treesitter.txt',
+ ['eq?'] = 'treesitter.txt',
+ ['lsp-request'] = 'lsp.txt',
+ matchit = 'vim_diff.txt',
+ ['matchit.txt'] = 'help.txt',
["set!"] = "treesitter.txt",
- ["v:_null_blob"] = "builtin.txt",
- ["v:_null_dict"] = "builtin.txt",
- ["v:_null_list"] = "builtin.txt",
- ["v:_null_string"] = "builtin.txt",
- ["vim.lsp.buf_request()"] = "lsp.txt",
- ["vim.lsp.util.get_progress_messages()"] = "lsp.txt",
- ["vim.treesitter.start()"] = "treesitter.txt",
+ ['v:_null_blob'] = 'builtin.txt',
+ ['v:_null_dict'] = 'builtin.txt',
+ ['v:_null_list'] = 'builtin.txt',
+ ['v:_null_string'] = 'builtin.txt',
+ ['vim.lsp.buf_request()'] = 'lsp.txt',
+ ['vim.lsp.util.get_progress_messages()'] = 'lsp.txt',
}
-- False-positive "invalid URLs".
diff --git a/scripts/genvimvim.lua b/scripts/genvimvim.lua
index 868084a583..3e9e7077be 100644
--- a/scripts/genvimvim.lua
+++ b/scripts/genvimvim.lua
@@ -11,6 +11,8 @@ local funcs_file = arg[3]
package.path = nvimsrcdir .. '/?.lua;' .. package.path
+_G.vim = loadfile(nvimsrcdir..'/../../runtime/lua/vim/shared.lua')()
+
local lld = {}
local syn_fd = io.open(syntax_file, 'w')
lld.line_length = 0
@@ -115,7 +117,7 @@ end
local nvimau_start = 'syn keyword nvimAutoEvent contained '
w('\n\n' .. nvimau_start)
-for au, _ in pairs(auevents.nvim_specific) do
+for au, _ in vim.spairs(auevents.nvim_specific) do
if lld.line_length > 850 then
w('\n' .. nvimau_start)
end
@@ -126,7 +128,7 @@ w('\n\nsyn case match')
local vimfun_start = 'syn keyword vimFuncName contained '
w('\n\n' .. vimfun_start)
local funcs = mpack.unpack(io.open(funcs_file, 'rb'):read("*all"))
-for name, _ in pairs(funcs) do
+for _, name in ipairs(funcs) do
if name then
if lld.line_length > 850 then
w('\n' .. vimfun_start)