changeset 561:6f07ecae3810

Create Ag command in config step
author Zeger Van de Vannet <zegervdv@me.com>
date Wed, 16 Feb 2022 08:56:31 +0100
parents c8b76a79611a
children fc435126a156
files .chezmoitemplates/init.lua
diffstat 1 files changed, 7 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/.chezmoitemplates/init.lua	Tue Feb 15 13:21:27 2022 +0100
+++ b/.chezmoitemplates/init.lua	Wed Feb 16 08:56:31 2022 +0100
@@ -205,9 +205,7 @@
         },
       }
 
-      vim.keymap.set({"x", "n"}, "gs", '<plug>(GrepperOperator)')
-    end,
-    setup = function()
+      vim.keymap.set({ 'x', 'n' }, 'gs', '<plug>(GrepperOperator)')
       vim.api.nvim_add_user_command(
         'Ag',
         'Grepper -noprompt -tool ag -grepprg rg --vimgrep <args>',
@@ -837,14 +835,18 @@
   if ls.expand_or_jumpable() then
     ls.expand_or_jump()
   end
-end, { silent = true })
+end, {
+  silent = true,
+})
 
 -- Go back to previous placeholder
 vim.keymap.set({ 'i', 's' }, '<c-j>', function()
   if ls.jumpable(-1) then
     ls.jump(-1)
   end
-end, { silent = true })
+end, {
+  silent = true,
+})
 
 -- Toggle options in snippets
 vim.keymap.set('i', '<c-l>', function()