refactor: go.nvim build checks for go binary before installing tools
This commit is contained in:
parent
94274b126a
commit
4acadc3ae4
|
|
@ -17,7 +17,11 @@ return {
|
||||||
"nvim-treesitter/nvim-treesitter",
|
"nvim-treesitter/nvim-treesitter",
|
||||||
},
|
},
|
||||||
ft = { "go", 'gomod' },
|
ft = { "go", 'gomod' },
|
||||||
build = ':lua require("go.install").update_all_sync()',
|
build = function()
|
||||||
|
if vim.fn.executable('go') == 1 then
|
||||||
|
require("go.install").update_all_sync()
|
||||||
|
end
|
||||||
|
end,
|
||||||
config = function()
|
config = function()
|
||||||
require("go").setup()
|
require("go").setup()
|
||||||
end,
|
end,
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue