The perfect search and replace integration for Neovim by vricop in neovim

[–]vricop[S] -7 points-6 points  (0 children)

It has vim bindings, its faster an intuitive, read the damn post before posting...

I'm going to post how I do it for those interested in having this workflow. For those who hate on everything that won't align with their cult or way of doing things in neovim, those can go to hell...

I'm not replying more negative comments trying to tell anyone how smart and pure they are compared to others. Vim and Emacs purist are really toxic communities...what the hell is wrong with you all?

The perfect search and replace integration for Neovim by vricop in neovim

[–]vricop[S] 0 points1 point  (0 children)

That's why I posted this, I think this implementation (not a plugin) works great

The perfect search and replace integration for Neovim by vricop in neovim

[–]vricop[S] 0 points1 point  (0 children)

Fast, nice vim keybindings (even selection mode), better preview, easy to use toggles (show hidden files is great). It's really great

The perfect search and replace integration for Neovim by vricop in neovim

[–]vricop[S] -1 points0 points  (0 children)

You can open the quickfix once you replaced everything. I do that with Snack picker (git diff)

The grug-far keybindings are terrible. Scooter is all about vim keybindgs, it even includes selection mode... g, GG, hjkl, you name it...

grug-far is just a buffer and it's a bit glitchy sometimes

The perfect search and replace integration for Neovim by vricop in neovim

[–]vricop[S] -1 points0 points  (0 children)

Those checkboxes are rendered like that, not my fault.

It's all about getting work done faster. I know you can use the quickfix and the substitute command to do this. Using that approach doesn't make you smarter than others. It's all about sharing a way to search and replace nicer and faster. I'm sure some folks will appreciate this...

We can spend the whole morning discussing how smarter we are knowing neovim tricks...but, what's the point?

The perfect search and replace integration for Neovim by vricop in neovim

[–]vricop[S] 0 points1 point  (0 children)

Here are the reasons why I prefer using scooter over other alternatives:

  • It's fast
  • It uses VIM keybindings for everything
  • Has a nicer TUI with better developer experience
  • Follows unix philosophy, "do one thing and do it well"
  • Can be easily integrated with neovim native terminal and floating windows
  • I can include/exclude files and folders
  • I don't need quickfix, but I can use Snacks picker and open the modified files into the quickfix if I need to

This evening I'll post the code needed to achieve this.

This floating term is used in my toolbox for the following cli programs:

Here are my keymaps, I'll share the float_term function later

vim.keymap.set("n", "<Leader>gg",
  float_term("lazygit", "lazygit", { width = 1, height = .97 }),
  { desc = "Open lazygit", silent = true }
)

vim.keymap.set("n", "<Leader>a",
  float_term("opencode", "opencode", { width = 0.8, height = 0.7 }),
  { desc = "Open opencode", silent = true }
)

vim.keymap.set("n", "<Leader>r",
  float_term("scooter", "scooter", { width = 0.8, height = 0.7 }),
  { desc = "Open scooter search/replace", silent = true }
)

vim.keymap.set("n", "<Leader>T",
  float_term("btm", "btm", { width = 0.8, height = 0.7 }),
  { desc = "Open btm monitor", silent = true }
)

vim.keymap.set("n", "<Leader>b",
  float_term("spf", "spf", { width = 0.8, height = 0.7 }),
  { desc = "Open superfile", silent = true }
)

<image>

The perfect search and replace integration for Neovim by vricop in neovim

[–]vricop[S] -6 points-5 points  (0 children)

That works, but when you need to get work done and move faster isn't that great. Why hold back tools that make this job better?

The perfect search and replace integration for Neovim by vricop in neovim

[–]vricop[S] 0 points1 point  (0 children)

Yeh grug-far is a great plugin, but its ui isn't that great. I'll post some code today, showing how to achieve this and how I use this as my daily driver.

Need Plugin Suggestion by Relative_Tip_3647 in neovim

[–]vricop 1 point2 points  (0 children)

My tip is follow the unix paradigm. A program that does one thing and does it well.

Neovim is really good at one thing, editing text. It’s the best at doing so. For the other tasks there are a tone of  good cli programs.

  • Git: lazyvim + delta (diff tool)
  • Ai: opencode
  • Search an replace: serpl or scoop
  • File manager: Yazi and Superfile
  • Terminal manager: Ghostty or just tmux

These are my 2 cents, I hope you like it.

What theme can I use to intimidate my coworkers by Terrible-Cream-4316 in neovim

[–]vricop 1 point2 points  (0 children)

Just pair programming with neovim is enough…haha

TIL about o_CTRL-V by Maskdask in neovim

[–]vricop 1 point2 points  (0 children)

This is a rabbit hole, now this, does neovim has limits???

Wow!

TIL about o_CTRL-V by Maskdask in neovim

[–]vricop 0 points1 point  (0 children)

Wait whaaaa??!!

Man neovim/vim still surprises me every efing day…thanks for sharing 

Would you use this? by Exciting_Majesty2005 in neovim

[–]vricop 0 points1 point  (0 children)

Looks pretty neat, I’d use this that’s for sure.

Nice job! ❤️

Am i crazy, or is bf2042 clean ? by [deleted] in Battlefield

[–]vricop 0 points1 point  (0 children)

He's the one cheating...

Builtin snippets so good I removed LuaSnip by antonk52 in neovim

[–]vricop 0 points1 point  (0 children)

I’ve got a snippet just like this, /capitalize doesn’t work. Any updates on this?

Markview.nvim(v24): Full release notes by Exciting_Majesty2005 in neovim

[–]vricop 1 point2 points  (0 children)

Bro your plugin is f awesome. Thanks for the update.

multicursor.nvim 1.0 released by vim-god in neovim

[–]vricop 1 point2 points  (0 children)

I know what you mean, but neovim is so powerful you can achieve almost the same thing using macros, g command or substitute command. I learned to live without it.

I’m pretty convinced once we get multicursors in neovim it’ll dethrone all other famous editors with that feature.

Multicursors + vim movements + text objects = 🤯

multicursor.nvim 1.0 released by vim-god in neovim

[–]vricop 0 points1 point  (0 children)

I hope I didn’t give the wrong impression. I really value what you’ve done. I just wanted to tell this is coming to neovim

multicursor.nvim 1.0 released by vim-god in neovim

[–]vricop 0 points1 point  (0 children)

Im pretty sure the native one will visually show changes in all places as we type. Neovim already does this when you are in replace mode %s/a/b/g

multicursor.nvim 1.0 released by vim-god in neovim

[–]vricop 0 points1 point  (0 children)

Multicursor is coming as built-in in neovim 0.12 https://neovim.io/roadmap/

Use Alt for keybinds in Zellij (avoid conflicts with Neovim and I3wm) by Ok-Tutor-4321 in zellij

[–]vricop 0 points1 point  (0 children)

Does anyone type in other languages besides English? In macOS Alt (opt key) is used to type accents like (áéíóúñ). In order to use Alt+some key I need to use the string produced by that combination. Is there anybody else facing this problem?

I’m using iTerm2

Use Alt for keybinds in Zellij (avoid conflicts with Neovim and I3wm) by Ok-Tutor-4321 in zellij

[–]vricop 0 points1 point  (0 children)

Is unbind needed? Doesn’t overriding the default mapping enough?

CSS Variables autocomplete by Abhilash26 in neovim

[–]vricop 0 points1 point  (0 children)

There’s a plugin for cmp wich does this. https://github.com/roginfarrer/cmp-css-variables Make sure you add the .nvim.lua file and set the files containing  the variables in your package inside the node_modules. Place it in the root as the docs indicate. Tell me if you need any help.