mirror of
https://github.com/chenasraf/nvim-treesitter.git
synced 2026-05-18 01:39:00 +00:00
feat(install): print more information when there's a failure
This commit is contained in:
committed by
Stephan Seitz
parent
013b0d1221
commit
2efeb80a44
@@ -49,9 +49,10 @@ local function iter_cmd_sync(cmd_list)
|
||||
print(cmd.info)
|
||||
end
|
||||
|
||||
vim.fn.system(get_command(cmd))
|
||||
local ret = vim.fn.system(get_command(cmd))
|
||||
if vim.v.shell_error ~= 0 then
|
||||
api.nvim_err_writeln(cmd.err or ("Failed to execute the following command:\n"..vim.inspect(cmd)))
|
||||
print(ret)
|
||||
api.nvim_err_writeln((cmd.err..'\n' or '').."Failed to execute the following command:\n"..vim.inspect(cmd))
|
||||
return false
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user