nvim,tmux,kitty: full config overhaul (AstroNvim → native 0.12)
Replaces AstroNvim v5 with from-scratch Neovim 0.12 config using vim.lsp.config()/vim.lsp.enable() natively, lazy.nvim, blink.cmp, and smart-splits tmux integration. tmux: new C-Space prefix, hjkl pane nav, resize key table, tpm plugins. kitty: add allow_remote_control for smart-splits.
This commit is contained in:
38
dot_config/nvim/lua/lsp/ltex.lua
Normal file
38
dot_config/nvim/lua/lsp/ltex.lua
Normal file
@@ -0,0 +1,38 @@
|
||||
-- LTeX grammar/spell checking for LaTeX and Markdown
|
||||
-- ltex_extra.nvim manages dictionaries/rules persistence
|
||||
vim.lsp.config("ltex", {
|
||||
filetypes = { "tex", "plaintex", "bib", "markdown" },
|
||||
settings = {
|
||||
ltex = {
|
||||
checkFrequency = "save",
|
||||
language = "en-GB",
|
||||
additionalRules = { motherTongue = "de-DE" },
|
||||
dictionary = {
|
||||
["en-GB"] = {},
|
||||
["de-DE"] = {},
|
||||
["fr-FR"] = {},
|
||||
},
|
||||
disabledRules = {
|
||||
["en-GB"] = {},
|
||||
["de-DE"] = {},
|
||||
["fr-FR"] = {},
|
||||
},
|
||||
hiddenFalsePositives = {
|
||||
["en-GB"] = {},
|
||||
["de-DE"] = {},
|
||||
["fr-FR"] = {},
|
||||
},
|
||||
},
|
||||
},
|
||||
on_attach = function(client, bufnr)
|
||||
local ok, ltex_extra = pcall(require, "ltex_extra")
|
||||
if ok then
|
||||
ltex_extra.setup({
|
||||
load_langs = { "en-GB", "de-DE", "fr-FR" },
|
||||
init_check = true,
|
||||
path = ".ltex",
|
||||
log_level = "none",
|
||||
})
|
||||
end
|
||||
end,
|
||||
})
|
||||
17
dot_config/nvim/lua/lsp/lua_ls.lua
Normal file
17
dot_config/nvim/lua/lsp/lua_ls.lua
Normal file
@@ -0,0 +1,17 @@
|
||||
vim.lsp.config("lua_ls", {
|
||||
settings = {
|
||||
Lua = {
|
||||
runtime = { version = "LuaJIT" },
|
||||
workspace = {
|
||||
checkThirdParty = false,
|
||||
library = {
|
||||
vim.env.VIMRUNTIME,
|
||||
"${3rd}/luv/library",
|
||||
},
|
||||
},
|
||||
diagnostics = { globals = { "vim" } },
|
||||
telemetry = { enable = false },
|
||||
format = { enable = false }, -- stylua handles formatting
|
||||
},
|
||||
},
|
||||
})
|
||||
1
dot_config/nvim/lua/lsp/marksman.lua
Normal file
1
dot_config/nvim/lua/lsp/marksman.lua
Normal file
@@ -0,0 +1 @@
|
||||
vim.lsp.config("marksman", {})
|
||||
40
dot_config/nvim/lua/lsp/rust_analyzer.lua
Normal file
40
dot_config/nvim/lua/lsp/rust_analyzer.lua
Normal file
@@ -0,0 +1,40 @@
|
||||
vim.lsp.config("rust_analyzer", {
|
||||
settings = {
|
||||
["rust-analyzer"] = {
|
||||
cargo = {
|
||||
allFeatures = true,
|
||||
loadOutDirsFromCheck = true,
|
||||
runBuildScripts = true,
|
||||
},
|
||||
checkOnSave = {
|
||||
allFeatures = true,
|
||||
command = "clippy",
|
||||
extraArgs = { "--no-deps" },
|
||||
},
|
||||
procMacro = {
|
||||
enable = true,
|
||||
ignored = {
|
||||
["async-trait"] = { "async_trait" },
|
||||
["napi-derive"] = { "napi" },
|
||||
["async-recursion"] = { "async_recursion" },
|
||||
},
|
||||
},
|
||||
inlayHints = {
|
||||
bindingModeHints = { enable = false },
|
||||
closingBraceHints = { minLines = 25 },
|
||||
lifetimeElisionHints = { enable = "never" },
|
||||
typeHints = { enable = true },
|
||||
},
|
||||
},
|
||||
},
|
||||
})
|
||||
|
||||
-- Support project-local override (e.g. Tauri: root_dir = src-tauri/)
|
||||
local local_cfg_path = vim.fn.getcwd() .. "/.nvim.lua"
|
||||
local local_cfg = vim.secure.read(local_cfg_path)
|
||||
if local_cfg then
|
||||
local ok, err = pcall(loadstring(local_cfg))
|
||||
if not ok then
|
||||
vim.notify("rust_analyzer local config error: " .. tostring(err), vim.log.levels.WARN)
|
||||
end
|
||||
end
|
||||
10
dot_config/nvim/lua/lsp/svelte.lua
Normal file
10
dot_config/nvim/lua/lsp/svelte.lua
Normal file
@@ -0,0 +1,10 @@
|
||||
vim.lsp.config("svelte", {
|
||||
on_attach = function(client, _)
|
||||
vim.api.nvim_create_autocmd("BufWritePost", {
|
||||
pattern = { "*.js", "*.ts" },
|
||||
callback = function(ctx)
|
||||
client.notify("$/onDidChangeTsOrJsFile", { uri = ctx.match })
|
||||
end,
|
||||
})
|
||||
end,
|
||||
})
|
||||
13
dot_config/nvim/lua/lsp/taplo.lua
Normal file
13
dot_config/nvim/lua/lsp/taplo.lua
Normal file
@@ -0,0 +1,13 @@
|
||||
vim.lsp.config("taplo", {
|
||||
settings = {
|
||||
evenBetterToml = {
|
||||
formatter = {
|
||||
indentTables = false,
|
||||
indentEntries = false,
|
||||
inlineTable = {},
|
||||
trailingNewline = true,
|
||||
reorderKeys = false,
|
||||
},
|
||||
},
|
||||
},
|
||||
})
|
||||
20
dot_config/nvim/lua/lsp/texlab.lua
Normal file
20
dot_config/nvim/lua/lsp/texlab.lua
Normal file
@@ -0,0 +1,20 @@
|
||||
vim.lsp.config("texlab", {
|
||||
settings = {
|
||||
texlab = {
|
||||
build = {
|
||||
executable = "latexmk",
|
||||
args = { "-pdf", "-interaction=nonstopmode", "-synctex=1", "%f" },
|
||||
onSave = false,
|
||||
forwardSearchAfter = false,
|
||||
},
|
||||
chktex = {
|
||||
onOpenAndSave = false,
|
||||
onEdit = false,
|
||||
},
|
||||
diagnosticsDelay = 300,
|
||||
formatterLineLength = 80,
|
||||
bibtexFormatter = "texlab",
|
||||
latexFormatter = "latexindent",
|
||||
},
|
||||
},
|
||||
})
|
||||
26
dot_config/nvim/lua/lsp/ts_ls.lua
Normal file
26
dot_config/nvim/lua/lsp/ts_ls.lua
Normal file
@@ -0,0 +1,26 @@
|
||||
vim.lsp.config("ts_ls", {
|
||||
settings = {
|
||||
typescript = {
|
||||
inlayHints = {
|
||||
includeInlayParameterNameHints = "all",
|
||||
includeInlayParameterNameHintsWhenArgumentMatchesName = false,
|
||||
includeInlayFunctionParameterTypeHints = true,
|
||||
includeInlayVariableTypeHints = true,
|
||||
includeInlayPropertyDeclarationTypeHints = true,
|
||||
includeInlayFunctionLikeReturnTypeHints = true,
|
||||
includeInlayEnumMemberValueHints = true,
|
||||
},
|
||||
},
|
||||
javascript = {
|
||||
inlayHints = {
|
||||
includeInlayParameterNameHints = "all",
|
||||
includeInlayParameterNameHintsWhenArgumentMatchesName = false,
|
||||
includeInlayFunctionParameterTypeHints = true,
|
||||
includeInlayVariableTypeHints = true,
|
||||
includeInlayPropertyDeclarationTypeHints = true,
|
||||
includeInlayFunctionLikeReturnTypeHints = true,
|
||||
includeInlayEnumMemberValueHints = true,
|
||||
},
|
||||
},
|
||||
},
|
||||
})
|
||||
11
dot_config/nvim/lua/lsp/yamlls.lua
Normal file
11
dot_config/nvim/lua/lsp/yamlls.lua
Normal file
@@ -0,0 +1,11 @@
|
||||
vim.lsp.config("yamlls", {
|
||||
settings = {
|
||||
yaml = {
|
||||
keyOrdering = false,
|
||||
format = { enable = true },
|
||||
validate = true,
|
||||
schemaStore = { enable = false, url = "" },
|
||||
schemas = {},
|
||||
},
|
||||
},
|
||||
})
|
||||
Reference in New Issue
Block a user