3 ms·
> Ask your local Vim nerd to rename the file they're editing. It will be entertaining! Oh that’s easy though, friend :) :!git mv % new-name > IDEs are declar
by phatskat 2y ago
> Ask your local Vim nerd to rename the file they're editing. It will be entertaining!
Oh that’s easy though, friend :)
:!git mv % new-name
> IDEs are declarative editors, you say "rename this variable" and they do it.
Most NeoVim setups I’ve tried recently include LSPs with code actions, so now I just hover a variable and do “<Space>ra” and I get a little popup window asking me for a new name. I type it, hit enter, and the reference is updated in all relevant files.
- deleted 2y ago[deleted]
- stevebmark 2y agoI was indeed entertained with your imperative instructions to move the file, which is also slightly more annoying if your file is not at the top level!
- phatskat 2y agoSlightly, but you can tab expand the % and then just edit the name at the end of the path