diff --git a/.github/.release-please-manifest.json b/.github/.release-please-manifest.json index d1d210f5..8b4f0289 100644 --- a/.github/.release-please-manifest.json +++ b/.github/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "14.9.0" + ".": "14.10.0" } diff --git a/CHANGELOG.md b/CHANGELOG.md index 7c9c762e..8117fbb6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,28 @@ # Changelog +## [14.10.0](https://github.com/LazyVim/LazyVim/compare/v14.9.0...v14.10.0) (2025-02-07) + + +### Features + +* **bufferline:** support for snacks picker sidebars ([3500d6a](https://github.com/LazyVim/LazyVim/commit/3500d6a826a32d06d921f3e22342734c61ef09fe)) +* **refactoring:** fallback to using vim ui select for refactoring.nvim ([#5540](https://github.com/LazyVim/LazyVim/issues/5540)) ([23a1bbd](https://github.com/LazyVim/LazyVim/commit/23a1bbdae90f37aab4a86bfb4c113531a28e7f71)) +* **snacks.explorer:** enabled netrw integration ([4f006f1](https://github.com/LazyVim/LazyVim/commit/4f006f1fba5fdaa0150c544ad7966b96ec9cb04a)) +* **snacks.picker:** add projects picker to dashboard if snacks picker is enabled ([fb256f2](https://github.com/LazyVim/LazyVim/commit/fb256f2b688cb7ac9875f704fe6c00f27efc2354)) +* **snacks.picker:** some extra keymaps ([ab30442](https://github.com/LazyVim/LazyVim/commit/ab304426527723e116742cd7862fc976f876107c)) +* **snippets:** mini.snippets is out of beta ([#5505](https://github.com/LazyVim/LazyVim/issues/5505)) ([4a81a37](https://github.com/LazyVim/LazyVim/commit/4a81a370d7868d7db32042f69b0fc5a6218059c5)) + + +### Bug Fixes + +* **copilot:** remove load on BufReadPost instead of InsertEnter ([8f4e9b8](https://github.com/LazyVim/LazyVim/commit/8f4e9b8c1e43e354d91529484aedca54f04bdcf6)) +* **go:** update go.lua to eliminate fieldalignment from analyses ([#5170](https://github.com/LazyVim/LazyVim/issues/5170)) ([5c97327](https://github.com/LazyVim/LazyVim/commit/5c9732733de62a4e15988826f53d16a4dfdf960c)) + + +### Performance Improvements + +* **snacks_picker:** lazy-load trouble open action ([1a4d948](https://github.com/LazyVim/LazyVim/commit/1a4d948e0dae360836187be8c86283d7e814b7ef)) + ## [14.9.0](https://github.com/LazyVim/LazyVim/compare/v14.8.0...v14.9.0) (2025-01-30) diff --git a/doc/LazyVim.txt b/doc/LazyVim.txt index 5c0ff0a2..43127781 100644 --- a/doc/LazyVim.txt +++ b/doc/LazyVim.txt @@ -1,4 +1,4 @@ -*LazyVim.txt* For Neovim Last change: 2025 January 30 +*LazyVim.txt* For Neovim Last change: 2025 February 07 ============================================================================== Table of Contents *LazyVim-table-of-contents* diff --git a/lua/lazyvim/config/init.lua b/lua/lazyvim/config/init.lua index cbe0a571..e2bf10d9 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 = "14.9.0" -- x-release-please-version +M.version = "14.10.0" -- x-release-please-version LazyVim.config = M ---@class LazyVimOptions diff --git a/lua/lazyvim/plugins/extras/ai/copilot.lua b/lua/lazyvim/plugins/extras/ai/copilot.lua index 4651c689..4f1d54f2 100644 --- a/lua/lazyvim/plugins/extras/ai/copilot.lua +++ b/lua/lazyvim/plugins/extras/ai/copilot.lua @@ -5,11 +5,12 @@ return { "zbirenbaum/copilot.lua", cmd = "Copilot", build = ":Copilot auth", - event = "InsertEnter", + event = "BufReadPost", opts = { suggestion = { enabled = not vim.g.ai_cmp, auto_trigger = true, + hide_during_completion = vim.g.ai_cmp, keymap = { accept = false, -- handled by nvim-cmp / blink.cmp next = "", diff --git a/lua/lazyvim/plugins/extras/coding/mini-snippets.lua b/lua/lazyvim/plugins/extras/coding/mini-snippets.lua index f68af110..5ce82c80 100644 --- a/lua/lazyvim/plugins/extras/coding/mini-snippets.lua +++ b/lua/lazyvim/plugins/extras/coding/mini-snippets.lua @@ -61,7 +61,7 @@ return { { "L3MON4D3/LuaSnip", optional = true, enabled = false }, -- add mini.snippets - desc = "mini.snippets(beta), a plugin to manage and expand snippets (alternative for luasnip)", + desc = "Manage and expand snippets (alternative to Luasnip)", { "echasnovski/mini.snippets", event = "InsertEnter", -- don't depend on other plugins to load... diff --git a/lua/lazyvim/plugins/extras/editor/refactoring.lua b/lua/lazyvim/plugins/extras/editor/refactoring.lua index 29920347..832940e9 100644 --- a/lua/lazyvim/plugins/extras/editor/refactoring.lua +++ b/lua/lazyvim/plugins/extras/editor/refactoring.lua @@ -1,10 +1,10 @@ local pick = function() + local refactoring = require("refactoring") if LazyVim.pick.picker.name == "telescope" then return require("telescope").extensions.refactoring.refactors() elseif LazyVim.pick.picker.name == "fzf" then local fzf_lua = require("fzf-lua") - local results = require("refactoring").get_refactors() - local refactoring = require("refactoring") + local results = refactoring.get_refactors() local opts = { fzf_opts = {}, @@ -16,6 +16,8 @@ local pick = function() }, } fzf_lua.fzf_exec(results, opts) + else + refactoring.select_refactor() end end diff --git a/lua/lazyvim/plugins/extras/editor/snacks_explorer.lua b/lua/lazyvim/plugins/extras/editor/snacks_explorer.lua index b45342f2..aa87e85c 100644 --- a/lua/lazyvim/plugins/extras/editor/snacks_explorer.lua +++ b/lua/lazyvim/plugins/extras/editor/snacks_explorer.lua @@ -2,36 +2,24 @@ return { { "nvim-neo-tree/neo-tree.nvim", enabled = false }, { "folke/snacks.nvim", + opts = { explorer = {} }, keys = { { "fe", function() - Snacks.picker.explorer({ cwd = LazyVim.root() }) + Snacks.explorer({ cwd = LazyVim.root() }) end, desc = "Explorer Snacks (root dir)", }, { "fE", function() - Snacks.picker.explorer() + Snacks.explorer() end, desc = "Explorer Snacks (cwd)", }, { "e", "fe", desc = "Explorer Snacks (root dir)", remap = true }, { "E", "fE", desc = "Explorer Snacks (cwd)", remap = true }, }, - init = function() - vim.api.nvim_create_autocmd("BufEnter", { - group = vim.api.nvim_create_augroup("snacks_explorer_start_directory", { clear = true }), - desc = "Start Snacks Explorer with directory", - once = true, - callback = function() - local dir = vim.fn.argv(0) --[[@as string]] - if dir ~= "" and vim.fn.isdirectory(dir) == 1 then - Snacks.picker.explorer({ cwd = dir }) - end - end, - }) - end, }, } diff --git a/lua/lazyvim/plugins/extras/editor/snacks_picker.lua b/lua/lazyvim/plugins/extras/editor/snacks_picker.lua index b6b6deee..bd160f26 100644 --- a/lua/lazyvim/plugins/extras/editor/snacks_picker.lua +++ b/lua/lazyvim/plugins/extras/editor/snacks_picker.lua @@ -75,6 +75,7 @@ return { { "gc", function() Snacks.picker.git_log() end, desc = "Git Log" }, { "gd", function() Snacks.picker.git_diff() end, desc = "Git Diff (hunks)" }, { "gs", function() Snacks.picker.git_status() end, desc = "Git Status" }, + { "gS", function() Snacks.picker.git_stash() end, desc = "Git Stash" }, -- Grep { "sb", function() Snacks.picker.lines() end, desc = "Buffer Lines" }, { "sB", function() Snacks.picker.grep_buffers() end, desc = "Grep Open Buffers" }, @@ -85,10 +86,12 @@ return { { "sW", LazyVim.pick("grep_word", { root = false }), desc = "Visual selection or word (cwd)", mode = { "n", "x" } }, -- search { 's"', function() Snacks.picker.registers() end, desc = "Registers" }, + { 's/', function() Snacks.picker.search_history() end, desc = "Search History" }, { "sa", function() Snacks.picker.autocmds() end, desc = "Autocmds" }, { "sc", function() Snacks.picker.command_history() end, desc = "Command History" }, { "sC", function() Snacks.picker.commands() end, desc = "Commands" }, { "sd", function() Snacks.picker.diagnostics() end, desc = "Diagnostics" }, + { "sD", function() Snacks.picker.diagnostics_buffer() end, desc = "Buffer Diagnostics" }, { "sh", function() Snacks.picker.help() end, desc = "Help Pages" }, { "sH", function() Snacks.picker.highlights() end, desc = "Highlights" }, { "si", function() Snacks.picker.icons() end, desc = "Icons" }, @@ -110,7 +113,11 @@ return { if LazyVim.has("trouble.nvim") then return vim.tbl_deep_extend("force", opts or {}, { picker = { - actions = require("trouble.sources.snacks").actions, + actions = { + trouble_open = function(...) + return require("trouble.sources.snacks").actions.trouble_open.action(...) + end, + }, win = { input = { keys = { diff --git a/lua/lazyvim/plugins/extras/lang/go.lua b/lua/lazyvim/plugins/extras/lang/go.lua index b9544cfd..bf3b22ee 100644 --- a/lua/lazyvim/plugins/extras/lang/go.lua +++ b/lua/lazyvim/plugins/extras/lang/go.lua @@ -37,7 +37,6 @@ return { rangeVariableTypes = true, }, analyses = { - fieldalignment = true, nilness = true, unusedparams = true, unusedwrite = true, diff --git a/lua/lazyvim/plugins/ui.lua b/lua/lazyvim/plugins/ui.lua index 6e03a217..0669054d 100644 --- a/lua/lazyvim/plugins/ui.lua +++ b/lua/lazyvim/plugins/ui.lua @@ -37,6 +37,9 @@ return { highlight = "Directory", text_align = "left", }, + { + filetype = "snacks_layout_box", + }, }, ---@param opts bufferline.IconFetcherOpts get_element_icon = function(opts) @@ -322,4 +325,18 @@ return { }, }, }, + { + "folke/snacks.nvim", + opts = function(_, opts) + if not opts.picker then + return + end + table.insert(opts.dashboard.preset.keys, 3, { + icon = " ", + key = "p", + desc = "Projects", + action = ":lua Snacks.picker.projects()", + }) + end, + }, }