Skip to content

Commit 47589b3

Browse files
committed
Merge remote changes with icon additions
- Resolved conflicts from GitHub repo merge - Added icons to Debug and Git groups in which-key - Added icons to scratchpad, notifications, projects, and git browse keymaps
2 parents c6a93d8 + 3f40fcd commit 47589b3

2 files changed

Lines changed: 12 additions & 60 deletions

File tree

lua/plugins/lsp.lua

Lines changed: 10 additions & 59 deletions
Original file line numberDiff line numberDiff line change
@@ -29,35 +29,21 @@ return {
2929
emmet_language_server = {
3030
fileeypes = { "html", "typescriptreact", "javascriptreact", "css", "sass", "scss", "php" },
3131
},
32-
eslint_d = {
33-
root_dir = vim.fs.root(0, { "package.json", ".eslintrc.json", ".eslintrc.js", ".git" }),
34-
filetypes = { "javascript", "typescript", "typescriptreact", "javascriptreact" },
35-
flags = os.getenv("DEBOUNCE_ESLINT") and {
36-
allow_incremental_sync = true,
37-
debounce_text_changes = 1000,
38-
} or nil,
39-
on_attach = function(_, bufnr)
40-
vim.api.nvim_create_autocmd("BufWritePre", {
41-
buffer = bufnr,
42-
command = "EslintFixAll",
43-
})
44-
end,
45-
},
4632
gopls = {},
4733
html = {},
4834
jsonls = {},
4935
lua_ls = {
5036
settings = {
51-
Lua = {
37+
lua = {
5238
diagnostics = {
53-
globals = { "vim", "Snacks" },
39+
globals = { "vim", "snacks" },
5440
},
5541
completion = {
56-
callSnippet = "Replace",
42+
callsnippet = "replace",
5743
},
5844
workspace = {
5945
library = vim.api.nvim_get_runtime_file("", true),
60-
checkThirdParty = false,
46+
checkthirdparty = false,
6147
},
6248
},
6349
},
@@ -172,54 +158,19 @@ return {
172158
---------------------
173159
-- mason
174160
---------------------
161+
175162
local ensure_installed = vim.tbl_keys(servers or {})
163+
local ensure_lsptools_installed = vim.tbl_keys(servers or {})
176164

177165
if vim.g.debugger then
178166
local DEBUGGERS = require("utils.debugger").DEBUGGERS
179-
vim.list_extend(ensure_installed, DEBUGGERS)
167+
vim.list_extend(ensure_lsptools_installed, DEBUGGERS)
180168
end
181169

182-
vim.list_extend(ensure_installed, LSP_TOOLS)
183-
184-
require("mason-tool-installer").setup({ ensure_installed = ensure_installed })
185-
require("mason-lspconfig").setup({
186-
handlers = {
187-
function(server_name)
188-
local server = servers[server_name] or {}
189-
server.capabilities = vim.tbl_deep_extend("force", {}, capabilities, server.capabilities or {})
190-
191-
-- Add memory limits for heavy LSP servers
192-
local heavy_servers = {
193-
"vtsls",
194-
"lua_ls",
195-
"pyright",
196-
"rust_analyzer",
197-
"gopls",
198-
"clangd",
199-
"tailwindcss",
200-
"jdtls",
201-
"yamlls",
202-
}
203-
if vim.tbl_contains(heavy_servers, server_name) then
204-
server.settings = server.settings or {}
205-
server.settings.memory = {
206-
limitMb = get_memory_limit_mb(),
207-
}
208-
end
170+
vim.list_extend(ensure_lsptools_installed, LSP_TOOLS)
209171

210-
-- Add offsetEncoding capability for clangd
211-
if server_name == "clangd" then
212-
server.capabilities.offsetEncoding = { "utf-16" }
213-
end
214-
215-
-- server.on_attach = function(client, bufnr) -- Attach to every buffer
216-
-- Populate Workspace-Diagnostics plugin information
217-
-- require("workspace-diagnostics").populate_workspace_diagnostics(client, bufnr)
218-
-- end
219-
require("lspconfig")[server_name].setup(server)
220-
end,
221-
},
222-
})
172+
require("mason-tool-installer").setup({ ensure_installed = ensure_lsptools_installed })
173+
require("mason-lspconfig").setup({ ensure_installed = ensure_installed, automatic_enable = true })
223174

224175
---------------------
225176
-- keybinds

lua/plugins/mini-sessions.lua

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,8 @@ return {
1515
pre = {
1616
read = nil,
1717
write = function()
18-
local edgy, diffview, dap, dapui = require("edgy"), require("diffview.lib"), require("dap"), require("dapui")
18+
local edgy, diffview, dap, dapui =
19+
require("edgy"), require("diffview.lib"), require("nvim-dap"), require("dapui")
1920

2021
edgy.close()
2122

0 commit comments

Comments
 (0)