Nvim: update config for lsp and add few minor plugins
This commit is contained in:
@@ -14,12 +14,13 @@ vim.g.mapleader = ' '
|
||||
vim.g.maplocalleader = ' '
|
||||
|
||||
vim.opt.rtp:prepend(lazypath)
|
||||
require'lazy'.setup('plugins', {
|
||||
change_detection = {
|
||||
enabled = true,
|
||||
notify = false
|
||||
},
|
||||
dev = {
|
||||
path = '/home/kmcr'
|
||||
}
|
||||
})
|
||||
require'lazy'.setup('plugins')
|
||||
-- , {
|
||||
-- change_detection = {
|
||||
-- enabled = false,
|
||||
-- notify = false
|
||||
-- },
|
||||
-- dev = {
|
||||
-- path = '/home/kmcr'
|
||||
-- }
|
||||
-- })
|
||||
|
||||
@@ -7,5 +7,6 @@ return {
|
||||
-- dev = true,
|
||||
config = function()
|
||||
require('bitbucket-nvim').setup({ opt = "test"})
|
||||
end
|
||||
end,
|
||||
enabled = false
|
||||
}
|
||||
|
||||
@@ -7,6 +7,7 @@ return { {
|
||||
'disrupted/blink-cmp-conventional-commits',
|
||||
'moyiz/blink-emoji.nvim',
|
||||
'milanglacier/minuet-ai.nvim',
|
||||
'mikavilpas/blink-ripgrep.nvim',
|
||||
},
|
||||
|
||||
-- use a release tag to download pre-built binaries
|
||||
@@ -41,7 +42,16 @@ return { {
|
||||
-- Default list of enabled providers defined so that you can extend it
|
||||
-- elsewhere in your config, without redefining it, due to `opts_extend`
|
||||
sources = {
|
||||
default = { 'conventional_commits', 'lsp', 'path', 'snippets', 'buffer', 'emoji', 'codecompanion', --[[ 'minuet' ]] },
|
||||
default = {
|
||||
'conventional_commits',
|
||||
'lsp',
|
||||
'path',
|
||||
'snippets',
|
||||
'buffer',
|
||||
'emoji',
|
||||
--'ripgrep',
|
||||
--[[ 'minuet' ]]
|
||||
},
|
||||
providers = {
|
||||
conventional_commits = {
|
||||
name = "Conventional Commits",
|
||||
@@ -69,6 +79,11 @@ return { {
|
||||
timeout_ms = 3000,
|
||||
score_offset = 50, -- Gives minuet higher priority among suggestions
|
||||
},
|
||||
ripgrep = {
|
||||
module = 'blink-ripgrep',
|
||||
name = 'Ripgrep',
|
||||
opts = {},
|
||||
},
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
@@ -45,4 +45,5 @@ return {
|
||||
log_level = "DEBUG",
|
||||
},
|
||||
},
|
||||
enabled = false
|
||||
}
|
||||
|
||||
@@ -44,6 +44,9 @@ return {
|
||||
-- 'm15a/nvim-srcerite', - requires buggy highlite
|
||||
'nyoom-engineering/oxocarbon.nvim',
|
||||
'rjshkhr/shadow.nvim',
|
||||
'folke/tokyonight.nvim',
|
||||
'nendix/zen.nvim',
|
||||
'mcauley-penney/techbase.nvim',
|
||||
'default'
|
||||
})
|
||||
end
|
||||
|
||||
@@ -31,5 +31,5 @@ return {
|
||||
hijack_file_patterns = { "*.png", "*.jpg", "*.jpeg", "*.gif", "*.webp", "*.avif", "*.svg" }, -- render image files as images when opened
|
||||
})
|
||||
end,
|
||||
enabled = true
|
||||
enabled = false
|
||||
}
|
||||
|
||||
@@ -8,9 +8,7 @@ return {
|
||||
{ url = "http://git.sr.ht/~p00f/clangd_extensions.nvim" },
|
||||
},
|
||||
config = function()
|
||||
local nvim_lsp = require('lspconfig')
|
||||
vim.lsp.config('clangd_extensions', {
|
||||
-- require('clangd_extensions').setup({
|
||||
require('clangd_extensions').setup({
|
||||
ast = {
|
||||
-- These are unicode, should be available in any font
|
||||
role_icons = {
|
||||
@@ -109,9 +107,9 @@ return {
|
||||
virtual_text = false,
|
||||
update_in_insert = false,
|
||||
severity_sort = true,
|
||||
virtual_lines = {
|
||||
current_line = true,
|
||||
}
|
||||
-- virtual_lines = {
|
||||
-- current_line = true,
|
||||
-- }
|
||||
})
|
||||
end
|
||||
})
|
||||
@@ -125,16 +123,22 @@ return {
|
||||
-- )
|
||||
--capabilities.offsetEncoding = { "utf-16" }
|
||||
|
||||
nvim_lsp.groovyls.setup({
|
||||
vim.lsp.config('groovyls', {
|
||||
cmd = { "java", "-jar", "/home/kmcr/tools/groovy-language-server/build/libs/groovy-language-server-all.jar" },
|
||||
capabilities = capabilities
|
||||
})
|
||||
|
||||
nvim_lsp.clangd.setup({
|
||||
vim.lsp.config('clangd_extensions', {
|
||||
cmd = {
|
||||
"/workspace/WayveCode/bzl-build/WayveCode/external/llvm_toolchain_llvm/bin/clangd",
|
||||
"--background-index",
|
||||
"-j=32",
|
||||
"--header-insertion=never"},
|
||||
capabilities = capabilities,
|
||||
filetypes = { "cpp" },
|
||||
})
|
||||
|
||||
nvim_lsp.pylsp.setup({
|
||||
vim.lsp.config('pylsp', {
|
||||
settings = {
|
||||
pylint = {
|
||||
enabled = true
|
||||
@@ -146,7 +150,7 @@ return {
|
||||
capabilities = capabilities
|
||||
})
|
||||
|
||||
nvim_lsp.lua_ls.setup({
|
||||
vim.lsp.config('lua_ls', {
|
||||
settings = {
|
||||
Lua = {
|
||||
diagnostics = { globals = { "vim" } },
|
||||
@@ -174,19 +178,19 @@ return {
|
||||
-- }
|
||||
-- })
|
||||
|
||||
nvim_lsp.typos_lsp.setup({
|
||||
vim.lsp.config('typos_lsp', {
|
||||
cmd = { 'typos-lsp' },
|
||||
filetypes = { '*' },
|
||||
root_dir = nvim_lsp.util.root_pattern('typos.toml', '_typos.toml', '.typos.toml'),
|
||||
root_dir = require("lspconfig.util").root_pattern('typos.toml', '_typos.toml', '.typos.toml'),
|
||||
single_file_support = true,
|
||||
settings = {},
|
||||
})
|
||||
|
||||
-- Use a loop to conveniently call 'setup' on multiple servers and
|
||||
-- map buffer local keybindings when the language server attaches
|
||||
local servers = { "cmake", "rust_analyzer", "bashls", "marksman" }
|
||||
local servers = { "cmake", "rust_analyzer", "bashls", "marksman", "bzl" }
|
||||
for _, lsp in ipairs(servers) do
|
||||
nvim_lsp[lsp].setup({
|
||||
vim.lsp.config(lsp, {
|
||||
capabilities = capabilities,
|
||||
})
|
||||
end
|
||||
|
||||
@@ -8,4 +8,8 @@ return {{
|
||||
}, {
|
||||
'mong8se/buffish.nvim',
|
||||
vim.keymap.set("n", "<leader>tb", function() require('buffish').open() end, { desc = "Open buffers list" })
|
||||
}, {
|
||||
"benomahony/oil-git.nvim",
|
||||
dependencies = { "stevearc/oil.nvim" },
|
||||
enabled = false
|
||||
}}
|
||||
|
||||
@@ -3,4 +3,5 @@ return {
|
||||
config = function()
|
||||
require("pendulum").setup()
|
||||
end,
|
||||
enabled = false
|
||||
}
|
||||
|
||||
@@ -6,11 +6,12 @@ return {
|
||||
'nvim-telescope/telescope-symbols.nvim',
|
||||
'mrloop/telescope-git-branch.nvim',
|
||||
{
|
||||
"isak102/telescope-git-file-history.nvim",
|
||||
dependencies = { "tpope/vim-fugitive" }
|
||||
'isak102/telescope-git-file-history.nvim',
|
||||
dependencies = { 'tpope/vim-fugitive' }
|
||||
},
|
||||
'kiyoon/telescope-insert-path.nvim',
|
||||
"zongben/navimark.nvim",
|
||||
'zongben/navimark.nvim',
|
||||
'johmsalas/text-case.nvim',
|
||||
},
|
||||
event = 'VeryLazy',
|
||||
--cmd = ":Telescope",
|
||||
@@ -56,6 +57,17 @@ return {
|
||||
},
|
||||
}
|
||||
}
|
||||
require('textcase').setup({
|
||||
enabled_methods = {
|
||||
"to_lower_case",
|
||||
"to_snake_case",
|
||||
"to_dash_case",
|
||||
"to_constant_case",
|
||||
"to_camel_case",
|
||||
"to_title_case",
|
||||
"to_path_case",
|
||||
}
|
||||
})
|
||||
require('telescope').load_extension('undo')
|
||||
require('telescope').load_extension('menufacture')
|
||||
require("telescope").load_extension("git_file_history")
|
||||
@@ -75,6 +87,8 @@ return {
|
||||
-- Neovim lsp pickers
|
||||
map('n', 'grr', function() require("telescope.builtin").lsp_references() end, def)
|
||||
map('n', 'gd', function() require("telescope.builtin").lsp_definitions() end, def)
|
||||
map('n', 'grt', "<cmd>TextCaseOpenTelescope<CR>", def)
|
||||
map('x', 'grt', "<cmd>TextCaseOpenTelescope<CR>", def)
|
||||
-- git pickers
|
||||
-- map('n', '<leader>gc', function() require("telescope.builtin").git_commits() end, def)
|
||||
-- map('n', '<leader>gC', function() require("telescope.builtin").git_bcommits() end, def)
|
||||
|
||||
@@ -41,7 +41,7 @@ return {
|
||||
"ini",
|
||||
"jq",
|
||||
"json",
|
||||
"latex",
|
||||
--"latex",
|
||||
"lua",
|
||||
"make",
|
||||
"markdown",
|
||||
|
||||
Reference in New Issue
Block a user