Skip to content

Commit 5c203ce

Browse files
committed
some updates from mac side
1 parent bbeec8b commit 5c203ce

2 files changed

Lines changed: 18 additions & 15 deletions

File tree

xdg_config/nvim/lua/tj/lsp/init.lua

Lines changed: 17 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -135,8 +135,6 @@ local custom_attach = function(client)
135135

136136
-- Set autocommands conditional on server_capabilities
137137
if client.server_capabilities.documentHighlightProvider then
138-
P(client.server_capabilities.documentHighlightProvider)
139-
140138
vim.cmd [[
141139
augroup lsp_document_highlight
142140
autocmd! * <buffer>
@@ -279,15 +277,11 @@ local setup_server = function(server, config)
279277
lspconfig[server].setup(config)
280278
end
281279

282-
for server, config in pairs(servers) do
283-
setup_server(server, config)
284-
end
285-
286280
if is_mac then
287281
local sumneko_cmd, sumneko_env = nil, nil
288282
require("nvim-lsp-installer").setup {
289283
automatic_installation = false,
290-
ensure_installed = { "sumneko_lua" },
284+
ensure_installed = { "sumneko_lua", "gopls" },
291285
}
292286

293287
sumneko_cmd = {
@@ -310,6 +304,18 @@ if is_mac then
310304
Lua = {
311305
diagnostics = {
312306
globals = {
307+
-- vim
308+
"vim",
309+
310+
-- Busted
311+
"describe",
312+
"it",
313+
"before_each",
314+
"after_each",
315+
"teardown",
316+
"pending",
317+
"clear",
318+
313319
-- Colorbuddy
314320
"Color",
315321
"c",
@@ -332,8 +338,6 @@ if is_mac then
332338
else
333339
-- Load lua configuration from nlua.
334340
_ = require("nlua.lsp.nvim").setup(lspconfig, {
335-
cmd = sumneko_cmd,
336-
cmd_env = sumneko_env,
337341
on_init = custom_init,
338342
on_attach = custom_attach,
339343
capabilities = updated_capabilities,
@@ -361,6 +365,10 @@ else
361365
})
362366
end
363367

368+
for server, config in pairs(servers) do
369+
setup_server(server, config)
370+
end
371+
364372
if pcall(require, "sg.lsp") then
365373
require("sg.lsp").setup {
366374
on_init = custom_init,

xdg_config/nvim/lua/tj/plugins.lua

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -27,12 +27,6 @@ if is_mac then
2727
max_jobs = 32
2828
end
2929

30-
require("packer").startup {
31-
function(use)
32-
use "wbthomason/packer.nvim"
33-
end,
34-
}
35-
3630
return require("packer").startup {
3731
function(use)
3832
local local_use = function(first, second, opts)
@@ -455,6 +449,7 @@ return require("packer").startup {
455449

456450
-- TREE SITTER:
457451
local_use("nvim-treesitter", "nvim-treesitter")
452+
use "nvim-treesitter/nvim-treesitter-context"
458453
use "nvim-treesitter/playground"
459454
use "vigoux/architext.nvim"
460455

0 commit comments

Comments
 (0)