all repos — dotfiles @ d892bfcf6741133441a7b07391d6ee5c330acc4a

linux dotfiles

nvim: add gopls lsp, set some options
Prithu Goswami pg@prithu.dev
Sun, 25 Sep 2022 23:58:53 +0530
commit

d892bfcf6741133441a7b07391d6ee5c330acc4a

parent

96694a0d43092ef7ab3aec86643e20396df36114

4 files changed, 10 insertions(+), 1 deletions(-)

jump to
M config/nvim/init.luaconfig/nvim/init.lua

@@ -117,7 +117,7 @@ null_ls.builtins.formatting.black.with({extra_args={"--fast"}}),

null_ls.builtins.formatting.isort, null_ls.builtins.diagnostics.flake8.with({ condition = function(utils) - return utils.root_has_file({"pyproject.toml", ".flake8"}) + return utils.root_has_file({".flake8"}) end, }), null_ls.builtins.diagnostics.mypy.with({
M config/nvim/lua/lsp/init.luaconfig/nvim/lua/lsp/init.lua

@@ -91,3 +91,8 @@ }

} } } + +lspconfig.gopls.setup{ + capabilities = capabilities, + on_attach = on_attach +}
M config/nvim/lua/options.luaconfig/nvim/lua/options.lua

@@ -6,6 +6,7 @@ vim.opt.smartindent = true

vim.opt.autoindent = true vim.opt.undofile = true --o.colorcolumn = '80' +vim.opt.scrolloff = 8 vim.opt.mouse = 'a' vim.opt.wildmenu = true vim.opt.showmatch = true

@@ -15,6 +16,8 @@ vim.opt.foldmethod = 'indent'

vim.opt.foldlevelstart = 10 vim.opt.foldnestmax = 10 vim.opt.number = true +vim.opt.signcolumn = "yes" +vim.opt.numberwidth = 4 vim.opt.backspace = 'indent,eol,start' vim.opt.termguicolors = true
M home/.profilehome/.profile

@@ -11,6 +11,7 @@ export OPENER=xdg-open

export PATH="$HOME/.cargo/bin:$PATH" export PATH="$HOME/.local/bin:$PATH" +export PATH="$HOME/go/bin:$PATH" source $HOME/.config/secrets export PATH="$HOME/.poetry/bin:$PATH"