diff --git a/.github/.release-please-manifest.json b/.github/.release-please-manifest.json index 350a6875..538e599a 100644 --- a/.github/.release-please-manifest.json +++ b/.github/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "15.12.2" + ".": "15.14.0" } diff --git a/.markdownlint-cli2.yaml b/.markdownlint-cli2.yaml new file mode 100644 index 00000000..fc2ac02c --- /dev/null +++ b/.markdownlint-cli2.yaml @@ -0,0 +1,3 @@ +config: + MD013: false + MD033: false diff --git a/CHANGELOG.md b/CHANGELOG.md index d81a5b74..f5e25695 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,43 @@ # Changelog +## [15.14.0](https://github.com/LazyVim/LazyVim/compare/v15.13.0...v15.14.0) (2026-03-01) + + +### Features + +* **bufferline:** add <leader>bj keymap for BufferLinePick ([#6968](https://github.com/LazyVim/LazyVim/issues/6968)) ([a50072f](https://github.com/LazyVim/LazyVim/commit/a50072fa16cfc1f00b1ae282150bc667f1d1e096)) +* **dap:** close dap-float window with `q`. ([#6884](https://github.com/LazyVim/LazyVim/issues/6884)) ([87c0027](https://github.com/LazyVim/LazyVim/commit/87c002789220d922bb94637c690b444bd1ba5611)) +* **treesitter:** support query table in treesitter-textobjects mappings ([#6736](https://github.com/LazyVim/LazyVim/issues/6736)) ([42c9f71](https://github.com/LazyVim/LazyVim/commit/42c9f7152b9bd1a4f739b115390370c208dc2a55)) + + +### Bug Fixes + +* **editor.overseer:** migrate to v2 ([#6907](https://github.com/LazyVim/LazyVim/issues/6907)) ([27824d7](https://github.com/LazyVim/LazyVim/commit/27824d79a952c54cd9d93c85a699543e4a031dd4)) +* **fzf:** correct git_diff description from 'hunks' to 'files' ([#6983](https://github.com/LazyVim/LazyVim/issues/6983)) ([e77d4ab](https://github.com/LazyVim/LazyVim/commit/e77d4ab0d6574efb7142ec40f4f5dcff750a3ee9)) +* **lang.clang:** fix `clangd_extensions.nvim` ([#6804](https://github.com/LazyVim/LazyVim/issues/6804)) ([730b691](https://github.com/LazyVim/LazyVim/commit/730b69114d56834f4499fd3e5aecf18920234c39)) +* **leap:** update urls to new leap.nvim repo. Fixes [#6958](https://github.com/LazyVim/LazyVim/issues/6958) ([244af66](https://github.com/LazyVim/LazyVim/commit/244af66f8b4e376d60c6604f9b3fd758165f5799)) +* **news:** resolve news.txt from $VIMRUNTIME first ([60fea62](https://github.com/LazyVim/LazyVim/commit/60fea6236e342e1f4aa34d078461746d5f587c74)), closes [#7019](https://github.com/LazyVim/LazyVim/issues/7019) +* **python:** set venv-selector.nvim override_notify = false ([#6936](https://github.com/LazyVim/LazyVim/issues/6936)) ([b2917bd](https://github.com/LazyVim/LazyVim/commit/b2917bd3bfe61c40e686f5a2c20f540430945b73)) +* **terminal:** add -NoProfile to powershell shellcmdflag ([#6757](https://github.com/LazyVim/LazyVim/issues/6757)) ([a507822](https://github.com/LazyVim/LazyVim/commit/a507822c0f67df661d1411f9274a65ca9cc832f5)) +* **terminal:** partially revert previous mappings ([#6770](https://github.com/LazyVim/LazyVim/issues/6770)) ([c64a617](https://github.com/LazyVim/LazyVim/commit/c64a61734fc9d45470a72603395c02137802bc6f)) +* **treesitter:** fix `]c` textobject mappings when in diff mode ([#6911](https://github.com/LazyVim/LazyVim/issues/6911)) ([16713e6](https://github.com/LazyVim/LazyVim/commit/16713e6e1200eb90ad4b4a394bb7254fb5612484)) +* **treesitter:** remove deleted jsonc parser ([#6848](https://github.com/LazyVim/LazyVim/issues/6848)) ([92607e7](https://github.com/LazyVim/LazyVim/commit/92607e79e09a2761d930877a09edc00438b97fc3)) +* **util.lsp:** `LazyVim.lsp.execute` only request single client ([#6904](https://github.com/LazyVim/LazyVim/issues/6904)) ([a4e19e9](https://github.com/LazyVim/LazyVim/commit/a4e19e9c9c939c1a3fc2f30ffefe37311d3ecadf)) +* **util.lsp:** pass `formatters_by_ft` to `opts` ([#6894](https://github.com/LazyVim/LazyVim/issues/6894)) ([03f1293](https://github.com/LazyVim/LazyVim/commit/03f1293e33541073288f23abdaf581a8e0dec4c4)) +* **vtsls:** remove redundant deno logic, upstreamed in `nvim-lspconfig` ([#7011](https://github.com/LazyVim/LazyVim/issues/7011)) ([8652c95](https://github.com/LazyVim/LazyVim/commit/8652c9570377678a78ecb19dbd33695e0e4ec4fc)) + +## [15.13.0](https://github.com/LazyVim/LazyVim/compare/v15.12.2...v15.13.0) (2025-11-01) + + +### Features + +* **snacks:** `snacks.gh` integration. Enabled by default, unless the `util.octo` extra is enabled. ([5e981f9](https://github.com/LazyVim/LazyVim/commit/5e981f9a8cd75eb6f49756e188411037b82b8045)) + + +### Bug Fixes + +* **treesitter:** remove node requirement ([6b52a30](https://github.com/LazyVim/LazyVim/commit/6b52a3059e52eed062b6ff3f56e70cffcbf879fe)) + ## [15.12.2](https://github.com/LazyVim/LazyVim/compare/v15.12.1...v15.12.2) (2025-10-26) diff --git a/lua/lazyvim/config/autocmds.lua b/lua/lazyvim/config/autocmds.lua index a86594a3..a0b058a6 100644 --- a/lua/lazyvim/config/autocmds.lua +++ b/lua/lazyvim/config/autocmds.lua @@ -56,6 +56,7 @@ vim.api.nvim_create_autocmd("FileType", { pattern = { "PlenaryTestPopup", "checkhealth", + "dap-float", "dbout", "gitsigns-blame", "grug-far", diff --git a/lua/lazyvim/config/init.lua b/lua/lazyvim/config/init.lua index 5e56a073..63355fcc 100644 --- a/lua/lazyvim/config/init.lua +++ b/lua/lazyvim/config/init.lua @@ -3,7 +3,7 @@ _G.LazyVim = require("lazyvim.util") ---@class LazyVimConfig: LazyVimOptions local M = {} -M.version = "15.12.2" -- x-release-please-version +M.version = "15.14.0" -- x-release-please-version LazyVim.config = M ---@class LazyVimOptions @@ -34,7 +34,9 @@ local defaults = { dots = "󰇘", }, ft = { - octo = "", + octo = " ", + gh = " ", + ["markdown.gh"] = " ", }, dap = { Stopped = { "󰁕 ", "DiagnosticWarn", "DapStoppedLine" }, diff --git a/lua/lazyvim/plugins/extras/editor/dial.lua b/lua/lazyvim/plugins/extras/editor/dial.lua index 7a9a76ae..3d9a18bf 100644 --- a/lua/lazyvim/plugins/extras/editor/dial.lua +++ b/lua/lazyvim/plugins/extras/editor/dial.lua @@ -53,20 +53,6 @@ return { cyclic = true, }) - local weekdays = augend.constant.new({ - elements = { - "Monday", - "Tuesday", - "Wednesday", - "Thursday", - "Friday", - "Saturday", - "Sunday", - }, - word = true, - cyclic = true, - }) - local months = augend.constant.new({ elements = { "January", @@ -86,15 +72,6 @@ return { cyclic = true, }) - local capitalized_boolean = augend.constant.new({ - elements = { - "True", - "False", - }, - word = true, - cyclic = true, - }) - return { dials_by_ft = { css = "css", @@ -116,11 +93,12 @@ return { augend.integer.alias.decimal_int, -- nonnegative and negative decimal number augend.integer.alias.hex, -- nonnegative hex number (0x01, 0x1a1f, etc.) augend.date.alias["%Y/%m/%d"], -- date (2022/02/19, etc.) + augend.constant.alias.en_weekday, -- Mon, Tue, ..., Sat, Sun + augend.constant.alias.en_weekday_full, -- Monday, Tuesday, ..., Saturday, Sunday ordinal_numbers, - weekdays, months, - capitalized_boolean, augend.constant.alias.bool, -- boolean value (true <-> false) + augend.constant.alias.Bool, -- boolean value (True <-> False) logical_alias, }, vue = { diff --git a/lua/lazyvim/plugins/extras/editor/fzf.lua b/lua/lazyvim/plugins/extras/editor/fzf.lua index f63716c5..4f703405 100644 --- a/lua/lazyvim/plugins/extras/editor/fzf.lua +++ b/lua/lazyvim/plugins/extras/editor/fzf.lua @@ -227,7 +227,7 @@ return { { "fR", LazyVim.pick("oldfiles", { cwd = vim.uv.cwd() }), desc = "Recent (cwd)" }, -- git { "gc", "FzfLua git_commits", desc = "Commits" }, - { "gd", "FzfLua git_diff", desc = "Git Diff (hunks)" }, + { "gd", "FzfLua git_diff", desc = "Git Diff (files)" }, { "gl", "FzfLua git_commits", desc = "Commits" }, { "gs", "FzfLua git_status", desc = "Status" }, { "gS", "FzfLua git_stash", desc = "Git Stash" }, diff --git a/lua/lazyvim/plugins/extras/editor/leap.lua b/lua/lazyvim/plugins/extras/editor/leap.lua index 3fe4c5e7..6e82423c 100644 --- a/lua/lazyvim/plugins/extras/editor/leap.lua +++ b/lua/lazyvim/plugins/extras/editor/leap.lua @@ -4,7 +4,7 @@ return { -- easily jump to any location and enhanced f/t motions for Leap { - "ggandor/flit.nvim", + url = "https://codeberg.org/andyg/leap.nvim.git", enabled = true, keys = function() ---@type LazyKeysSpec[] @@ -17,7 +17,7 @@ return { opts = { labeled_modes = "nx" }, }, { - "ggandor/leap.nvim", + url = "https://codeberg.org/andyg/leap.nvim.git", enabled = true, keys = { { "s", mode = { "n", "x", "o" }, desc = "Leap Forward to" }, diff --git a/lua/lazyvim/plugins/extras/editor/overseer.lua b/lua/lazyvim/plugins/extras/editor/overseer.lua index 373c0029..c29a13a4 100644 --- a/lua/lazyvim/plugins/extras/editor/overseer.lua +++ b/lua/lazyvim/plugins/extras/editor/overseer.lua @@ -8,29 +8,20 @@ return { }, { "stevearc/overseer.nvim", + lazy = false, -- plugin is self-lazy-loading cmd = { "OverseerOpen", "OverseerClose", "OverseerToggle", - "OverseerSaveBundle", - "OverseerLoadBundle", - "OverseerDeleteBundle", - "OverseerRunCmd", "OverseerRun", - "OverseerInfo", - "OverseerBuild", - "OverseerQuickAction", "OverseerTaskAction", - "OverseerClearCache", }, opts = { dap = false, task_list = { - bindings = { - [""] = false, + keymaps = { [""] = false, [""] = false, - [""] = false, }, }, form = { @@ -38,11 +29,6 @@ return { winblend = 0, }, }, - confirm = { - win_opts = { - winblend = 0, - }, - }, task_win = { win_opts = { winblend = 0, @@ -51,13 +37,9 @@ return { }, -- stylua: ignore keys = { - { "ow", "OverseerToggle", desc = "Task list" }, - { "oo", "OverseerRun", desc = "Run task" }, - { "oq", "OverseerQuickAction", desc = "Action recent task" }, - { "oi", "OverseerInfo", desc = "Overseer Info" }, - { "ob", "OverseerBuild", desc = "Task builder" }, - { "ot", "OverseerTaskAction", desc = "Task action" }, - { "oc", "OverseerClearCache", desc = "Clear cache" }, + { "ow", "OverseerToggle!", desc = "Task list" }, + { "oo", "OverseerRun", desc = "Run task" }, + { "ot", "OverseerTaskAction", desc = "Task action" }, }, }, { diff --git a/lua/lazyvim/plugins/extras/editor/snacks_picker.lua b/lua/lazyvim/plugins/extras/editor/snacks_picker.lua index 48eea01a..6220bfdf 100644 --- a/lua/lazyvim/plugins/extras/editor/snacks_picker.lua +++ b/lua/lazyvim/plugins/extras/editor/snacks_picker.lua @@ -73,9 +73,13 @@ return { { "fp", function() Snacks.picker.projects() end, desc = "Projects" }, -- git { "gd", function() Snacks.picker.git_diff() end, desc = "Git Diff (hunks)" }, - { "gD", function() Snacks.picker.git_diff({ base = "origin" }) end, desc = "Git Diff (origin)" }, + { "gD", function() Snacks.picker.git_diff({ base = "origin", group = true }) end, desc = "Git Diff (origin)" }, { "gs", function() Snacks.picker.git_status() end, desc = "Git Status" }, { "gS", function() Snacks.picker.git_stash() end, desc = "Git Stash" }, + { "gi", function() Snacks.picker.gh_issue() end, desc = "GitHub Issues (open)" }, + { "gI", function() Snacks.picker.gh_issue({ state = "all" }) end, desc = "GitHub Issues (all)" }, + { "gp", function() Snacks.picker.gh_pr() end, desc = "GitHub Pull Requests (open)" }, + { "gP", function() Snacks.picker.gh_pr({ state = "all" }) end, desc = "GitHub Pull Requests (all)" }, -- Grep { "sb", function() Snacks.picker.lines() end, desc = "Buffer Lines" }, { "sB", function() Snacks.picker.grep_buffers() end, desc = "Grep Open Buffers" }, diff --git a/lua/lazyvim/plugins/extras/lang/clangd.lua b/lua/lazyvim/plugins/extras/lang/clangd.lua index cac83194..0dc3a3f5 100644 --- a/lua/lazyvim/plugins/extras/lang/clangd.lua +++ b/lua/lazyvim/plugins/extras/lang/clangd.lua @@ -23,8 +23,7 @@ return { { "p00f/clangd_extensions.nvim", - lazy = true, - config = function() end, + ft = { "c", "cpp", "objc", "objcpp" }, opts = { inlay_hints = { inline = false, @@ -94,13 +93,6 @@ return { }, }, }, - setup = { - clangd = function(_, opts) - local clangd_ext_opts = LazyVim.opts("clangd_extensions.nvim") - require("clangd_extensions").setup(vim.tbl_deep_extend("force", clangd_ext_opts or {}, { server = opts })) - return false - end, - }, }, }, diff --git a/lua/lazyvim/plugins/extras/lang/elixir.lua b/lua/lazyvim/plugins/extras/lang/elixir.lua index 289e50df..1be9c846 100644 --- a/lua/lazyvim/plugins/extras/lang/elixir.lua +++ b/lua/lazyvim/plugins/extras/lang/elixir.lua @@ -16,6 +16,8 @@ return { function() local params = vim.lsp.util.make_position_params() LazyVim.lsp.execute({ + title = "toPipe", + filter = "elixirls", command = "manipulatePipes:serverid", arguments = { "toPipe", params.textDocument.uri, params.position.line, params.position.character }, }) @@ -27,6 +29,8 @@ return { function() local params = vim.lsp.util.make_position_params() LazyVim.lsp.execute({ + title = "fromPipe", + filter = "elixirls", command = "manipulatePipes:serverid", arguments = { "fromPipe", params.textDocument.uri, params.position.line, params.position.character }, }) diff --git a/lua/lazyvim/plugins/extras/lang/python.lua b/lua/lazyvim/plugins/extras/lang/python.lua index bfe9e210..eb0bd5a8 100644 --- a/lua/lazyvim/plugins/extras/lang/python.lua +++ b/lua/lazyvim/plugins/extras/lang/python.lua @@ -114,6 +114,7 @@ return { opts = { options = { notify_user_on_venv_activation = true, + override_notify = false, }, }, -- Call config for Python files and load the cached venv automatically diff --git a/lua/lazyvim/plugins/extras/lang/typescript.lua b/lua/lazyvim/plugins/extras/lang/typescript.lua index bf52ecea..3a909d13 100644 --- a/lua/lazyvim/plugins/extras/lang/typescript.lua +++ b/lua/lazyvim/plugins/extras/lang/typescript.lua @@ -130,7 +130,11 @@ return { { "cV", function() - LazyVim.lsp.execute({ command = "typescript.selectTypeScriptVersion" }) + LazyVim.lsp.execute({ + title = "Select TypeScript Version", + filter = "vtsls", + command = "typescript.selectTypeScriptVersion", + }) end, desc = "Select TS workspace version", }, @@ -149,28 +153,6 @@ return { return true end, vtsls = function(_, opts) - if vim.lsp.config.denols and vim.lsp.config.vtsls then - ---@param server string - local resolve = function(server) - local markers, root_dir = vim.lsp.config[server].root_markers, vim.lsp.config[server].root_dir - vim.lsp.config(server, { - root_dir = function(bufnr, on_dir) - local is_deno = vim.fs.root(bufnr, { "deno.json", "deno.jsonc" }) ~= nil - if is_deno == (server == "denols") then - if root_dir then - return root_dir(bufnr, on_dir) - elseif type(markers) == "table" then - local root = vim.fs.root(bufnr, markers) - return root and on_dir(root) - end - end - end, - }) - end - resolve("denols") - resolve("vtsls") - end - Snacks.util.lsp.on({ name = "vtsls" }, function(buffer, client) client.commands["_typescript.moveToFileRefactoring"] = function(command, ctx) ---@type string, string, lsp.Range diff --git a/lua/lazyvim/plugins/extras/lang/typst.lua b/lua/lazyvim/plugins/extras/lang/typst.lua index 099a6861..9f605351 100644 --- a/lua/lazyvim/plugins/extras/lang/typst.lua +++ b/lua/lazyvim/plugins/extras/lang/typst.lua @@ -24,6 +24,8 @@ return { local buf_name = vim.api.nvim_buf_get_name(0) local file_name = vim.fn.fnamemodify(buf_name, ":t") LazyVim.lsp.execute({ + title = "Pin Main", + filter = "tinymist", command = "tinymist.pinMain", arguments = { buf_name }, }) diff --git a/lua/lazyvim/plugins/extras/ui/mini-indentscope.lua b/lua/lazyvim/plugins/extras/ui/mini-indentscope.lua index e043432c..8c25dfa7 100644 --- a/lua/lazyvim/plugins/extras/ui/mini-indentscope.lua +++ b/lua/lazyvim/plugins/extras/ui/mini-indentscope.lua @@ -55,7 +55,7 @@ return { }, }, - -- disable snacks scroll when mini-indentscope is enabled + -- disable snacks scope when mini-indentscope is enabled { "snacks.nvim", opts = { diff --git a/lua/lazyvim/plugins/extras/util/octo.lua b/lua/lazyvim/plugins/extras/util/octo.lua index d3316f5e..5637b8fd 100644 --- a/lua/lazyvim/plugins/extras/util/octo.lua +++ b/lua/lazyvim/plugins/extras/util/octo.lua @@ -3,6 +3,16 @@ return { -- depends on the git extra for highlighting and auto-completion of github issues/prs { import = "lazyvim.plugins.extras.lang.git" }, + { + "folke/snacks.nvim", + keys = { -- disable conflicting keymaps + { "gi", false }, + { "gI", false }, + { "gp", false }, + { "gP", false }, + }, + }, + -- Octo { "pwntester/octo.nvim", diff --git a/lua/lazyvim/plugins/lsp/init.lua b/lua/lazyvim/plugins/lsp/init.lua index 540b6c5c..1a3708e1 100644 --- a/lua/lazyvim/plugins/lsp/init.lua +++ b/lua/lazyvim/plugins/lsp/init.lua @@ -2,7 +2,7 @@ return { -- lspconfig { "neovim/nvim-lspconfig", - event = "LazyFile", + event = { "BufReadPre", "BufNewFile" }, dependencies = { "mason.nvim", { "mason-org/mason-lspconfig.nvim", config = function() end }, @@ -150,7 +150,7 @@ return { return ret end, ---@param opts PluginLspOpts - config = vim.schedule_wrap(function(_, opts) + config = function(_, opts) -- setup autoformat LazyVim.format.register(LazyVim.lsp.formatter()) @@ -259,7 +259,7 @@ return { automatic_enable = { exclude = mason_exclude }, }) end - end), + end, }, -- cmdline tools and lsp servers diff --git a/lua/lazyvim/plugins/treesitter.lua b/lua/lazyvim/plugins/treesitter.lua index 7fee6c38..6de91b30 100644 --- a/lua/lazyvim/plugins/treesitter.lua +++ b/lua/lazyvim/plugins/treesitter.lua @@ -37,7 +37,6 @@ return { "javascript", "jsdoc", "json", - "jsonc", "lua", "luadoc", "luap", @@ -171,19 +170,26 @@ return { for method, keymaps in pairs(moves) do for key, query in pairs(keymaps) do - local desc = query:gsub("@", ""):gsub("%..*", "") - desc = desc:sub(1, 1):upper() .. desc:sub(2) + local queries = type(query) == "table" and query or { query } + local parts = {} + for _, q in ipairs(queries) do + local part = q:gsub("@", ""):gsub("%..*", "") + part = part:sub(1, 1):upper() .. part:sub(2) + table.insert(parts, part) + end + local desc = table.concat(parts, " or ") desc = (key:sub(1, 1) == "[" and "Prev " or "Next ") .. desc desc = desc .. (key:sub(2, 2) == key:sub(2, 2):upper() and " End" or " Start") - if not (vim.wo.diff and key:find("[cC]")) then - vim.keymap.set({ "n", "x", "o" }, key, function() - require("nvim-treesitter-textobjects.move")[method](query, "textobjects") - end, { - buffer = buf, - desc = desc, - silent = true, - }) - end + vim.keymap.set({ "n", "x", "o" }, key, function() + if vim.wo.diff and key:find("[cC]") then + return vim.cmd("normal! " .. key) + end + require("nvim-treesitter-textobjects.move")[method](query, "textobjects") + end, { + buffer = buf, + desc = desc, + silent = true, + }) end end end diff --git a/lua/lazyvim/plugins/ui.lua b/lua/lazyvim/plugins/ui.lua index 23afdc39..041648b7 100644 --- a/lua/lazyvim/plugins/ui.lua +++ b/lua/lazyvim/plugins/ui.lua @@ -15,6 +15,7 @@ return { { "]b", "BufferLineCycleNext", desc = "Next Buffer" }, { "[B", "BufferLineMovePrev", desc = "Move buffer prev" }, { "]B", "BufferLineMoveNext", desc = "Move buffer next" }, + { "bj", "BufferLinePick", desc = "Pick Buffer" }, }, opts = { options = { diff --git a/lua/lazyvim/plugins/util.lua b/lua/lazyvim/plugins/util.lua index 0357c3fb..8d8aa220 100644 --- a/lua/lazyvim/plugins/util.lua +++ b/lua/lazyvim/plugins/util.lua @@ -23,8 +23,6 @@ return { nav_j = { "", term_nav("j"), desc = "Go to Lower Window", expr = true, mode = "t" }, nav_k = { "", term_nav("k"), desc = "Go to Upper Window", expr = true, mode = "t" }, nav_l = { "", term_nav("l"), desc = "Go to Right Window", expr = true, mode = "t" }, - hide_slash = { "", "hide", desc = "Hide Terminal", mode = { "t", "n" } }, - hide_underscore = { "", "hide", desc = "which_key_ignore", mode = { "t", "n" } }, }, }, }, diff --git a/lua/lazyvim/util/lsp.lua b/lua/lazyvim/util/lsp.lua index 90a6a3c7..ff248599 100644 --- a/lua/lazyvim/util/lsp.lua +++ b/lua/lazyvim/util/lsp.lua @@ -35,18 +35,14 @@ end ---@param opts? lsp.Client.format function M.format(opts) - opts = vim.tbl_deep_extend( - "force", - {}, - opts or {}, - LazyVim.opts("nvim-lspconfig").format or {}, - LazyVim.opts("conform.nvim").format or {} - ) + opts = vim.tbl_deep_extend("force", {}, opts or {}, LazyVim.opts("nvim-lspconfig").format or {}) local ok, conform = pcall(require, "conform") -- use conform for formatting with LSP when available, -- since it has better format diffing if ok then - opts.formatters = {} + -- It should be `nil`, otherwise it doesn't fetch options from `formatters_by_ft`, + -- see https://github.com/stevearc/conform.nvim/blob/5420c4b5ea0aeb99c09cfbd4fd0b70d257b44f25/lua/conform/init.lua#L417-L418 + opts.formatters = nil conform.format(opts) else vim.lsp.buf.format(opts) @@ -70,9 +66,18 @@ M.action = setmetatable({}, { ---@class LspCommand: lsp.ExecuteCommandParams ---@field open? boolean ---@field handler? lsp.Handler +---@field filter? string|vim.lsp.get_clients.Filter +---@field title? string ---@param opts LspCommand function M.execute(opts) + local filter = opts.filter or {} + filter = type(filter) == "string" and { name = filter } or filter + local buf = vim.api.nvim_get_current_buf() + + ---@cast filter vim.lsp.get_clients.Filter + local client = vim.lsp.get_clients(LazyVim.merge({}, filter, { bufnr = buf }))[1] + local params = { command = opts.command, arguments = opts.arguments, @@ -83,7 +88,8 @@ function M.execute(opts) params = params, }) else - return vim.lsp.buf_request(0, "workspace/executeCommand", params, opts.handler) + vim.list_extend(params, { title = opts.title }) + return client:exec_cmd(params, { bufnr = buf }, opts.handler) end end diff --git a/lua/lazyvim/util/news.lua b/lua/lazyvim/util/news.lua index f473f3a3..c891133f 100644 --- a/lua/lazyvim/util/news.lua +++ b/lua/lazyvim/util/news.lua @@ -51,7 +51,9 @@ function M.open(file, opts) end file = plugin.dir .. "/" .. file elseif opts.rtp then - file = vim.api.nvim_get_runtime_file(file, false)[1] + -- first check if file exists in VIMRUNTIME, then check the full runtimepath + local path = vim.env.VIMRUNTIME .. "/" .. file --[[@as string]] + file = vim.uv.fs_stat(path) and path or vim.api.nvim_get_runtime_file(file, false)[1] end if not file then diff --git a/lua/lazyvim/util/plugin.lua b/lua/lazyvim/util/plugin.lua index 02e6834f..696665e6 100644 --- a/lua/lazyvim/util/plugin.lua +++ b/lua/lazyvim/util/plugin.lua @@ -42,6 +42,7 @@ M.renames = { ["markdown.nvim"] = "render-markdown.nvim", ["williamboman/mason.nvim"] = "mason-org/mason.nvim", ["williamboman/mason-lspconfig.nvim"] = "mason-org/mason-lspconfig.nvim", + ["ggandor/leap.nvim"] = "https://codeberg.org/andyg/leap.nvim.git", } function M.save_core() diff --git a/lua/lazyvim/util/terminal.lua b/lua/lazyvim/util/terminal.lua index 0e1af758..4270d9c0 100644 --- a/lua/lazyvim/util/terminal.lua +++ b/lua/lazyvim/util/terminal.lua @@ -18,7 +18,7 @@ function M.setup(shell) -- Setting shell command flags vim.o.shellcmdflag = - "-NoLogo -NonInteractive -ExecutionPolicy RemoteSigned -Command [Console]::InputEncoding=[Console]::OutputEncoding=[System.Text.UTF8Encoding]::new();$PSDefaultParameterValues['Out-File:Encoding']='utf8';$PSStyle.OutputRendering='plaintext';Remove-Alias -Force -ErrorAction SilentlyContinue tee;" + "-NoProfile -NoLogo -NonInteractive -ExecutionPolicy RemoteSigned -Command [Console]::InputEncoding=[Console]::OutputEncoding=[System.Text.UTF8Encoding]::new();$PSDefaultParameterValues['Out-File:Encoding']='utf8';$PSStyle.OutputRendering='plaintext';Remove-Alias -Force -ErrorAction SilentlyContinue tee;" -- Setting shell redirection vim.o.shellredir = '2>&1 | %%{ "$_" } | Out-File %s; exit $LastExitCode' diff --git a/lua/lazyvim/util/treesitter.lua b/lua/lazyvim/util/treesitter.lua index e8688a6f..c21908c6 100644 --- a/lua/lazyvim/util/treesitter.lua +++ b/lua/lazyvim/util/treesitter.lua @@ -80,7 +80,6 @@ function M.check() ["C compiler"] = have_cc, tar = have("tar"), curl = have("curl"), - node = have("node"), } local ok = true for _, v in pairs(ret) do diff --git a/tests/extras/extra_spec.lua b/tests/extras/extra_spec.lua index f383c4b9..14f8d741 100644 --- a/tests/extras/extra_spec.lua +++ b/tests/extras/extra_spec.lua @@ -77,10 +77,12 @@ describe("Extra", function() it("it has no renamed plugins", function() for _, p in pairs(spec.plugins) do local short_url = p[1] - assert( - not LazyVim.plugin.renames[short_url], - "Plugin " .. short_url .. " has been renamed to " .. (LazyVim.plugin.renames[short_url] or "") - ) + if short_url then + assert( + not LazyVim.plugin.renames[short_url], + "Plugin " .. short_url .. " has been renamed to " .. (LazyVim.plugin.renames[short_url] or "") + ) + end end end)