Last active
October 20, 2023 08:45
-
-
Save wjkoh/b5677ccfd23cda39a4e7dae9bb736031 to your computer and use it in GitHub Desktop.
LazyVim: Install go.nvim plugin
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Copy this file to your ~/.config/nvim/lua/plugins/. | |
-- Add $GOPATH/bin to $PATH. For example, `set -Ux GOPATH $HOME/go && fish_add_path $GOPATH/bin` | |
-- Consider using https://github.com/fatih/vim-go instead of go.nvim. | |
return { | |
{ | |
"ray-x/go.nvim", | |
dependencies = { -- optional packages | |
"ray-x/guihua.lua", | |
"neovim/nvim-lspconfig", | |
"nvim-treesitter/nvim-treesitter", | |
}, | |
config = function() | |
require("go").setup() | |
end, | |
event = { "CmdlineEnter" }, | |
ft = { "go", "gomod" }, | |
build = ':lua require("go.install").update_all_sync()', -- if you need to install/update all binaries | |
}, | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment