2023-07-12 22:53:47 +02:00
|
|
|
-- return {
|
|
|
|
-- 'fatih/vim-go',
|
|
|
|
-- }
|
2023-06-06 16:14:20 +02:00
|
|
|
return {
|
2023-07-12 22:53:47 +02:00
|
|
|
"ray-x/go.nvim",
|
|
|
|
dependencies = { -- optional packages
|
|
|
|
"ray-x/guihua.lua",
|
|
|
|
"neovim/nvim-lspconfig",
|
|
|
|
"nvim-treesitter/nvim-treesitter",
|
|
|
|
},
|
|
|
|
config = function()
|
2023-07-26 21:11:04 +02:00
|
|
|
-- local gofmt = require("go.format")
|
2023-07-12 22:53:47 +02:00
|
|
|
require("go").setup()
|
2023-07-26 21:11:04 +02:00
|
|
|
|
|
|
|
-- vim.keymap.set('n', 'gF', gofmt.goimport, { desc = 'Go Import' })
|
2023-07-12 22:53:47 +02:00
|
|
|
end,
|
|
|
|
event = { "CmdlineEnter" },
|
|
|
|
ft = { "go", 'gomod' },
|
|
|
|
build = ':lua require("go.install").update_all_sync()' -- if you need to install/update all binaries
|
2023-06-06 16:14:20 +02:00
|
|
|
}
|