Merge branch 'master' of https://git.cscherr.de/PlexSheep/neovim-confs
This commit is contained in:
commit
7de28493eb
|
@ -5,8 +5,8 @@ local M = {}
|
||||||
local highlights = require "custom.highlights"
|
local highlights = require "custom.highlights"
|
||||||
|
|
||||||
M.ui = {
|
M.ui = {
|
||||||
theme = "kanagawa",
|
theme = "oceanic-next",
|
||||||
theme_toggle = { "kanagawa", "chadracula" },
|
theme_toggle = { "kanagawa", "oceanic-next" },
|
||||||
|
|
||||||
hl_override = highlights.override,
|
hl_override = highlights.override,
|
||||||
hl_add = highlights.add,
|
hl_add = highlights.add,
|
||||||
|
|
|
@ -10,7 +10,7 @@ local servers = {
|
||||||
"tsserver",
|
"tsserver",
|
||||||
"clangd",
|
"clangd",
|
||||||
"pyright",
|
"pyright",
|
||||||
-- "rust_analyzer",
|
"rust_analyzer", -- rustaceanvim wants to do that, but the builtin thing has better integration!
|
||||||
"bashls",
|
"bashls",
|
||||||
"cmake",
|
"cmake",
|
||||||
}
|
}
|
||||||
|
|
|
@ -219,6 +219,10 @@ M.telescope = {
|
||||||
["<localleader>th"] = { "<cmd> Telescope themes <cr>", "Nvchad themes" },
|
["<localleader>th"] = { "<cmd> Telescope themes <cr>", "Nvchad themes" },
|
||||||
|
|
||||||
["<localleader>ma"] = { "<cmd> Telescope marks <cr>", "telescope bookmarks" },
|
["<localleader>ma"] = { "<cmd> Telescope marks <cr>", "telescope bookmarks" },
|
||||||
|
|
||||||
|
-- lsp stuff
|
||||||
|
["<localleader>cw"] = { "<cmd> Telescope lsp_dynamic_workspace_symbols <cr>", "telescope dynamic workspace symbols" },
|
||||||
|
["<localleader>cd"] = { "<cmd> Telescope lsp_document_symbols <cr>", "telescope document symbols" },
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -348,7 +348,9 @@ local plugins = {
|
||||||
},
|
},
|
||||||
messages = {
|
messages = {
|
||||||
enabled = true,
|
enabled = true,
|
||||||
view_error = "messages", -- so it does not spam boxes with errors
|
-- NOTE: we keep it with notify,
|
||||||
|
-- change this to something else if you want
|
||||||
|
view_error = "notify",
|
||||||
},
|
},
|
||||||
popupmenu = {
|
popupmenu = {
|
||||||
enabled = true,
|
enabled = true,
|
||||||
|
@ -734,7 +736,6 @@ local plugins = {
|
||||||
end,
|
end,
|
||||||
config = function()
|
config = function()
|
||||||
local dap = require "dap"
|
local dap = require "dap"
|
||||||
local rustcfg = require "rustaceanvim.config"
|
|
||||||
local mason_registry = require "mason-registry"
|
local mason_registry = require "mason-registry"
|
||||||
local codelldb_root = mason_registry.get_package("codelldb"):get_install_path() .. "/extension/"
|
local codelldb_root = mason_registry.get_package("codelldb"):get_install_path() .. "/extension/"
|
||||||
local codelldb_path = codelldb_root .. "adapter/codelldb"
|
local codelldb_path = codelldb_root .. "adapter/codelldb"
|
||||||
|
@ -743,12 +744,17 @@ local plugins = {
|
||||||
command = "/home/plex/.local/bin/kitty",
|
command = "/home/plex/.local/bin/kitty",
|
||||||
args = {},
|
args = {},
|
||||||
}
|
}
|
||||||
dap.adapters.lldb = {
|
dap.adapters.gdb = {
|
||||||
|
type = "executable",
|
||||||
|
command = "gdb",
|
||||||
|
args = { "-i", "dap" },
|
||||||
|
}
|
||||||
|
dap.adapters.codelldb = {
|
||||||
type = "server",
|
type = "server",
|
||||||
port = "${port}",
|
port = "30333",
|
||||||
executable = {
|
executable = {
|
||||||
command = codelldb_path,
|
command = codelldb_path,
|
||||||
args = { "--port", "${port}" },
|
args = { "--port", "30333" },
|
||||||
detached = false,
|
detached = false,
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
@ -761,11 +767,12 @@ local plugins = {
|
||||||
return vim.fn.input("Path to executable: ", vim.fn.getcwd() .. "/", "file")
|
return vim.fn.input("Path to executable: ", vim.fn.getcwd() .. "/", "file")
|
||||||
end,
|
end,
|
||||||
cwd = "${workspaceFolder}",
|
cwd = "${workspaceFolder}",
|
||||||
|
-- FIXME: perhaps we can put the stdio somewhere more practical
|
||||||
stopOnEntry = false,
|
stopOnEntry = false,
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
dap.configurations.c = dap.configurations.cpp
|
dap.configurations.c = dap.configurations.cpp
|
||||||
-- dap.configurations.rust = dap.configurations.cpp
|
dap.configurations.rust = dap.configurations.cpp
|
||||||
end,
|
end,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -784,16 +791,17 @@ local plugins = {
|
||||||
dapui.open {}
|
dapui.open {}
|
||||||
end
|
end
|
||||||
dap.listeners.before.event_terminated["dapui_config"] = function()
|
dap.listeners.before.event_terminated["dapui_config"] = function()
|
||||||
dapui.close {}
|
-- dapui.close {}
|
||||||
end
|
end
|
||||||
dap.listeners.before.event_exited["dapui_config"] = function()
|
dap.listeners.before.event_exited["dapui_config"] = function()
|
||||||
dapui.close {}
|
-- dapui.close {}
|
||||||
end
|
end
|
||||||
end,
|
end,
|
||||||
},
|
},
|
||||||
{ "folke/neodev.nvim", opts = {} },
|
{ "folke/neodev.nvim", opts = {} },
|
||||||
{
|
{
|
||||||
"mrcjkb/rustaceanvim",
|
"mrcjkb/rustaceanvim",
|
||||||
|
enabled = true,
|
||||||
version = "^4", -- Recommended
|
version = "^4", -- Recommended
|
||||||
ft = { "rust" },
|
ft = { "rust" },
|
||||||
},
|
},
|
||||||
|
@ -802,6 +810,28 @@ local plugins = {
|
||||||
lazy = false, -- PERF: this can be done more elegant
|
lazy = false, -- PERF: this can be done more elegant
|
||||||
config = function()
|
config = function()
|
||||||
require("nvim-dap-virtual-text").setup()
|
require("nvim-dap-virtual-text").setup()
|
||||||
|
local dap = require "dap"
|
||||||
|
vim.g.rustaceanvim = {
|
||||||
|
-- Plugin configuration
|
||||||
|
tools = {},
|
||||||
|
-- LSP configuration
|
||||||
|
server = {
|
||||||
|
on_attach = function(client, bufnr)
|
||||||
|
-- you can also put keymaps in here
|
||||||
|
end,
|
||||||
|
settings = {
|
||||||
|
-- rust-analyzer language server configuration
|
||||||
|
["rust-analyzer"] = {},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
-- DAP configuration
|
||||||
|
dap = {
|
||||||
|
-- FIXME: the rustaceanvim debug config does not map the stdout/stderr to the
|
||||||
|
-- opened terminal, effectively rendering debugging with it useless. Luckily,
|
||||||
|
-- we can use the regular nvim-dap and nvim-dap-ui.
|
||||||
|
adapter = dap.adapters.codelldb,
|
||||||
|
},
|
||||||
|
}
|
||||||
end,
|
end,
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue