346 current 1970-01-01 01:00:00 23.11.20240522.4639777 6.6.30-rt30 *

This commit is contained in:
Max Känner 2024-05-26 14:56:58 +02:00
parent 9baa192388
commit 71fa64ccfa
4 changed files with 65 additions and 2 deletions

View File

@ -16,7 +16,6 @@ in {
defaultEditor = true; defaultEditor = true;
plugins = with pkgs.vimPlugins; [ plugins = with pkgs.vimPlugins; [
lazy-nvim lazy-nvim
nvim-treesitter-parsers.rust
]; ];
extraLuaConfig = '' extraLuaConfig = ''
require "lazy_setup" require "lazy_setup"

View File

@ -12,7 +12,7 @@ require("lazy").setup({
}, },
}, },
{ import = "community" }, { import = "community" },
-- { import = "plugins" }, { import = "plugins" },
} --[[@as LazySpec]], { } --[[@as LazySpec]], {
-- Configure any other `lazy.nvim` configuration options here -- Configure any other `lazy.nvim` configuration options here
install = { colorscheme = { "astrodark", "habamax" } }, install = { colorscheme = { "astrodark", "habamax" } },

View File

@ -0,0 +1,35 @@
---@type LazySpec
return {
"AstroNvim/astrocore",
opts = {
options = {
opt = {
relativenumber = false,
number = true,
spell = true,
signcolumn = "yes",
wrap = true,
colorcolumn = "80,120",
},
g = {
inlay_hints_enabled = true,
},
},
lsp = {
config = {
rust_analyzer = {
settings = {
["rust-analyzer"] = {
cargo = { buildScripts = { enable = true } },
procMacro = { enable = true },
check = {
command = "clippy",
},
},
},
},
clangd = { capabilities = { offsetEncoding = "utf-8" } },
},
},
},
}

View File

@ -0,0 +1,29 @@
return {
{
"p00f/clangd_extensions.nvim",
optional = true,
opts = { extensions = { autoSetHints = true } },
init = function()
--load clangd extensions when clangd attaches
local augroup = vim.api.nvim_create_augroup("clangd_extensions", { clear = true })
vim.api.nvim_create_autocmd("LspAttach", {
group = augroup,
desc = "Load clangd_extensions with clangd",
callback = function(args)
if assert(vim.lsp.get_client_by_id(args.data.client_id)).name == "clangd" then
require("clangd_extensions")
require("clangd_extensions.inlay_hints").setup_autocmd()
require("clangd_extensions.inlay_hints").set_inlay_hints()
vim.api.nvim_del_augroup_by_id(augroup)
end
end,
})
end,
},
{
"simrat39/rust-tools.nvim",
optional = true,
opts = { tools = { inlay_hints = { auto = true } } },
},
}