Format and fix clangd offset encoding

This commit is contained in:
Max Känner 2023-11-13 16:42:29 +01:00
parent cc9db47086
commit b8e5f74d25

View File

@ -1,21 +1,12 @@
local config = { local config = {
options = { options = { opt = { colorcolumn = "80,120" }, g = { inlay_hints_enabled = true } },
opt = {
colorcolumn = "80,120",
},
g = {
inlay_hints_enabled = true,
},
},
lsp = { lsp = {
config = { config = {
rust_analyzer = { rust_analyzer = {
settings = { settings = {
["rust-analyzer"] = { ["rust-analyzer"] = {
cargo = { cargo = { buildScripts = { enable = true } },
buildScripts = { enable = true },
},
procMacrto = { enable = true }, procMacrto = { enable = true },
check = { check = {
command = "clippy", command = "clippy",
@ -24,15 +15,14 @@ local config = {
}, },
}, },
}, },
clangd = { capabilities = { offsetEncoding = "utf-8" } },
}, },
}, },
-- Add plugins -- Add plugins
plugins = { plugins = {
-- Extended file type support -- Extended file type support
{ "sheerun/vim-polyglot", lazy = false }, { "sheerun/vim-polyglot", lazy = false }, -- Community plugins
-- Community plugins
"AstroNvim/astrocommunity", "AstroNvim/astrocommunity",
{ import = "astrocommunity.pack.angular" }, { import = "astrocommunity.pack.angular" },
{ import = "astrocommunity.pack.ansible" }, { import = "astrocommunity.pack.ansible" },
@ -84,7 +74,7 @@ local config = {
{ import = "astrocommunity.git.git-blame-nvim" }, { import = "astrocommunity.git.git-blame-nvim" },
{ import = "astrocommunity.markdown-and-latex.vimtex" }, { import = "astrocommunity.markdown-and-latex.vimtex" },
-- use moden inlay hints: -- use modern inlay hints:
{ {
"p00f/clangd_extensions.nvim", "p00f/clangd_extensions.nvim",
optional = true, optional = true,
@ -93,11 +83,7 @@ local config = {
{ {
"simrat39/rust-tools.nvim", "simrat39/rust-tools.nvim",
optional = true, optional = true,
opts = { opts = { tools = { inlay_hints = { auto = true } } },
tools = {
inlay_hints = { auto = true },
},
},
}, },
}, },
} }