diff --git a/lua/pack/configs/conform.lua b/lua/pack/configs/conform.lua index fa658cb..92da78e 100644 --- a/lua/pack/configs/conform.lua +++ b/lua/pack/configs/conform.lua @@ -12,7 +12,7 @@ local P = { -- 提取出统一的配置变量 local formatters_by_ft = { python = { "isort", "black" }, - rust = { "rust-analyzer", lsp_format = "fallback" }, + rust = { "rustfmt", lsp_format = "fallback" }, toml = { "templ" }, sh = { "shfmt" }, zsh = { "shfmt" }, diff --git a/lua/pack/configs/illuminate.lua b/lua/pack/configs/illuminate.lua index 5a5cd0b..e582434 100644 --- a/lua/pack/configs/illuminate.lua +++ b/lua/pack/configs/illuminate.lua @@ -1,4 +1,4 @@ --- === 插件描述 === +-- === 高亮当前文件所有引用 === if vim.g.vscode then return end vim.keymap.set( diff --git a/lua/pack/configs/lspconfig.lua b/lua/pack/configs/lspconfig.lua index 5ff601d..5b63e05 100644 --- a/lua/pack/configs/lspconfig.lua +++ b/lua/pack/configs/lspconfig.lua @@ -1,9 +1,18 @@ -- === LSP 核心配置 (Lspconfig + Mason) === if vim.g.vscode then return end -local servers = { "lua_ls", "rust_analyzer", "pylsp", "denols", } +local servers = { + "lua_ls", + "rust_analyzer", + "pylsp", + "vtsls", -- javascript +} if not IS_ARM then - vim.list_extend(servers, { "marksman", "svelte", "cssls", "html" }) + vim.list_extend(servers, { + "marksman", + "svelte", + "cssls", + "html" }) end -- 插件配置清单 diff --git a/lua/pack/configs/treesitter.lua b/lua/pack/configs/treesitter.lua index dd78a79..1db7367 100644 --- a/lua/pack/configs/treesitter.lua +++ b/lua/pack/configs/treesitter.lua @@ -16,6 +16,9 @@ local ensure_installed = { "markdown", "sh", "java", + "javascript", + "html", + "css", } -- 在 FileType 确定时,检查、安装并启动