From e01f1d6f5d42fac643facecd9ca2d240d53453bd Mon Sep 17 00:00:00 2001 From: sommerfeld Date: Fri, 17 Apr 2026 10:53:20 +0100 Subject: feat: migrate from lazy.nvim to vim.pack MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Replace lazy.nvim plugin manager with Neovim 0.12's native vim.pack API. All plugin config files rewritten from lazy.nvim spec tables to imperative require/setup format with explicit vim.keymap.set() calls. Key changes: - vim.pack.add() with ~53 plugins in init.lua - blink.cmp/pairs/download pinned to version tags (vim.version.range) - PackChanged autocmd for markdown-preview build hook - Ordered requires: colorscheme → ui → treesitter → completion → lsp → rest - Plugin setup guards (gitsigns, which-key, blink.cmp) handle deferred plugin/ file loading correctly Net reduction: ~438 lines across 13 files. --- home/.config/nvim/lua/plugins/search.lua | 175 ++++++++++--------------------- 1 file changed, 58 insertions(+), 117 deletions(-) (limited to 'home/.config/nvim/lua/plugins/search.lua') diff --git a/home/.config/nvim/lua/plugins/search.lua b/home/.config/nvim/lua/plugins/search.lua index e889c4c..a36cddc 100644 --- a/home/.config/nvim/lua/plugins/search.lua +++ b/home/.config/nvim/lua/plugins/search.lua @@ -1,119 +1,60 @@ -return { - { - "ibhagwan/fzf-lua", - branch = "main", - keys = { - { - "b", - function() - require("fzf-lua").buffers() - end, - desc = "fzf-lua [B]uffers", - }, - { - "/", - function() - require("fzf-lua").live_grep() - end, - desc = "fzf-lua live grep", - }, - { - "f", - function() - require("fzf-lua").files() - end, - desc = "fzf-lua [F]iles", - }, - { - "", - function() - require("fzf-lua").global() - end, - desc = "fzf-lua global picker", - }, - { - "d", - function() - require("fzf-lua").diagnostics() - end, - desc = "fzf-lua [D]iagnostics", - }, - { - "r", - function() - require("fzf-lua").resume() - end, - desc = "fzf-lua [R]esume", - }, - { - "gc", - function() - require("fzf-lua").git_bcommits() - end, - mode = "n", - desc = "[G]it buffer [C]commits", - }, - { - "gc", - function() - require("fzf-lua").git_bcommits_range() - end, - mode = "v", - desc = "[G]it [C]commits for selected range", - }, - { - "gC", - function() - require("fzf-lua").git_commits() - end, - desc = "[G]it (all) [C]commits", - }, - { - "gb", - function() - require("fzf-lua").git_branches() - end, - desc = "[G]it [B]ranches", - }, - { - "gs", - function() - require("fzf-lua").git_status() - end, - desc = "[G]it [S]tatus", - }, - { - "gS", - function() - require("fzf-lua").git_stash() - end, - desc = "[G]it [S]tash", - }, +local fzflua = require("fzf-lua") +fzflua.setup({ + keymap = { + builtin = { + true, + [""] = "toggle-preview", }, - config = function() - local fzflua = require("fzf-lua") - fzflua.setup({ - keymap = { - builtin = { - true, - [""] = "toggle-preview", - }, - }, - grep = { - hidden = true, - RIPGREP_CONFIG_PATH = "~/.config/ripgrep/ripgreprc", - }, - lsp = { - includeDeclaration = false, - }, - actions = { - files = { - true, - ["ctrl-x"] = fzflua.actions.file_split, - }, - }, - }) - fzflua.register_ui_select() - end, }, -} + grep = { + hidden = true, + RIPGREP_CONFIG_PATH = "~/.config/ripgrep/ripgreprc", + }, + lsp = { + includeDeclaration = false, + }, + actions = { + files = { + true, + ["ctrl-x"] = fzflua.actions.file_split, + }, + }, +}) +fzflua.register_ui_select() + +vim.keymap.set("n", "b", function() + fzflua.buffers() +end, { desc = "fzf-lua [B]uffers" }) +vim.keymap.set("n", "/", function() + fzflua.live_grep() +end, { desc = "fzf-lua live grep" }) +vim.keymap.set("n", "f", function() + fzflua.files() +end, { desc = "fzf-lua [F]iles" }) +vim.keymap.set("n", "", function() + fzflua.global() +end, { desc = "fzf-lua global picker" }) +vim.keymap.set("n", "d", function() + fzflua.diagnostics() +end, { desc = "fzf-lua [D]iagnostics" }) +vim.keymap.set("n", "r", function() + fzflua.resume() +end, { desc = "fzf-lua [R]esume" }) +vim.keymap.set("n", "gc", function() + fzflua.git_bcommits() +end, { desc = "[G]it buffer [C]commits" }) +vim.keymap.set("v", "gc", function() + fzflua.git_bcommits_range() +end, { desc = "[G]it [C]commits for selected range" }) +vim.keymap.set("n", "gC", function() + fzflua.git_commits() +end, { desc = "[G]it (all) [C]commits" }) +vim.keymap.set("n", "gb", function() + fzflua.git_branches() +end, { desc = "[G]it [B]ranches" }) +vim.keymap.set("n", "gs", function() + fzflua.git_status() +end, { desc = "[G]it [S]tatus" }) +vim.keymap.set("n", "gS", function() + fzflua.git_stash() +end, { desc = "[G]it [S]tash" }) -- cgit v1.2.3-70-g09d2