From fcab70e06325f123030a9442aef001707a603950 Mon Sep 17 00:00:00 2001 From: sommerfeld Date: Fri, 17 Apr 2026 10:53:11 +0100 Subject: refactor: flatten custom/plugins/ to plugins/ Rename lua/custom/plugins/ to lua/plugins/ following the standard lazy.nvim convention. The extra custom/ nesting added no value. Update import path in init.lua accordingly. --- home/.config/nvim/lua/custom/plugins/search.lua | 183 ------------------------ 1 file changed, 183 deletions(-) delete mode 100644 home/.config/nvim/lua/custom/plugins/search.lua (limited to 'home/.config/nvim/lua/custom/plugins/search.lua') diff --git a/home/.config/nvim/lua/custom/plugins/search.lua b/home/.config/nvim/lua/custom/plugins/search.lua deleted file mode 100644 index 40d8395..0000000 --- a/home/.config/nvim/lua/custom/plugins/search.lua +++ /dev/null @@ -1,183 +0,0 @@ -return { - { - "ibhagwan/fzf-lua", - branch = "main", - keys = { - { - "b", - function() - require("fzf-lua").buffers() - end, - desc = "fzf-lua by [G]rep", - }, - { - "g", - function() - require("fzf-lua").live_grep() - end, - desc = "fzf-lua by [G]rep", - }, - { - "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", - }, - }, - 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, - }, - }, - }) - vim.api.nvim_create_autocmd("LspAttach", { - callback = function(event) - local bnmap = function(keys, func, desc) - vim.keymap.set( - "n", - keys, - func, - { buffer = event.buf, desc = "LSP: " .. desc } - ) - end - bnmap("gd", fzflua.lsp_definitions, "[G]oto [D]efinition") - bnmap("gvd", function() - fzflua.lsp_definitions({ jump1_action = fzflua.actions.file_vsplit }) - end, "[G]oto in a [V]ertical split to [D]efinition") - bnmap("gxd", function() - fzflua.lsp_definitions({ jump1_action = fzflua.actions.file_split }) - end, "[G]oto in a [X]horizontal split to [D]efinition") - bnmap("gtd", function() - fzflua.lsp_definitions({ - jump1_action = fzflua.actions.file_tabedit, - }) - end, "[G]oto in a [T]ab to [D]efinition") - bnmap("D", fzflua.lsp_typedefs, "Type [D]efinition") - bnmap("vD", function() - fzflua.lsp_typedefs({ jump1_action = fzflua.actions.file_vsplit }) - end, "Open in a [V]ertical split Type [D]efinition") - bnmap("xD", function() - fzflua.lsp_typedefs({ jump1_action = fzflua.actions.file_split }) - end, "Open in a [X]horizontal split Type [D]efinition") - bnmap("tD", function() - fzflua.lsp_typedefs({ jump1_action = fzflua.actions.file_tabedit }) - end, "Open in a [T]ab Type [D]efinition") - bnmap("gri", fzflua.lsp_implementations, "[G]oto [I]mplementation") - bnmap("grvi", function() - fzflua.lsp_implementations({ - jump1_action = fzflua.actions.file_vsplit, - }) - end, "[G]oto in a [V]ertical split to [I]mplementation") - bnmap("grxi", function() - fzflua.lsp_implementations({ - jump1_action = fzflua.actions.file_split, - }) - end, "[G]oto in a [X]horizontal split to [I]mplementation") - bnmap("grti", function() - fzflua.lsp_implementations({ - jump1_action = fzflua.actions.file_tabedit, - }) - end, "[G]oto in a [T]ab to [I]mplementation") - bnmap("grr", fzflua.lsp_references, "[G]oto [R]eferences") - bnmap("ic", fzflua.lsp_incoming_calls, "[I]ncoming [C]alls") - bnmap("oc", fzflua.lsp_outgoing_calls, "[O]utgoing [C]alls") - bnmap("gO", fzflua.lsp_document_symbols, "d[O]ocument symbols") - bnmap( - "ws", - fzflua.lsp_live_workspace_symbols, - "[W]orkspace [S]ymbols" - ) - bnmap( - "wd", - fzflua.diagnostics_workspace, - "[W]orkspace [D]iagnostics" - ) - end, - }) - fzflua.register_ui_select() - end, - }, -} -- cgit v1.2.3-70-g09d2