mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-22 21:30:06 -04:00
fixup
This commit is contained in:
parent
4eaca06ee2
commit
a0a5753679
3 changed files with 8 additions and 13 deletions
|
|
@ -21,19 +21,14 @@ vim.opt.runtimepath:append('.')
|
|||
-- needed on CI
|
||||
vim.fn.mkdir(vim.fn.stdpath('cache'), 'p')
|
||||
|
||||
local task = nil
|
||||
if update then
|
||||
--- @type async.Task
|
||||
task = require('nvim-treesitter.install').update('all')
|
||||
else
|
||||
--- @type async.Task
|
||||
task = require('nvim-treesitter.install').install(
|
||||
---@type async.Task
|
||||
local task = update and require('nvim-treesitter.install').update('all')
|
||||
or require('nvim-treesitter.install').install(
|
||||
#parsers > 0 and parsers or 'all',
|
||||
{ force = true, generate = generate, max_jobs = max_jobs }
|
||||
)
|
||||
end
|
||||
|
||||
local ok, err_or_ok = task:pwait(6000000)
|
||||
local ok, err_or_ok = task:pwait(1800000) -- wait max. 30 minutes
|
||||
if not ok then
|
||||
print('ERROR: ', err_or_ok)
|
||||
vim.cmd.cq()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue