cmap w!! w !sudo tee > /dev/null %
this post was submitted on 20 Jun 2024
30 points (96.9% liked)
Neovim
2161 readers
3 users here now
founded 1 year ago
MODERATORS
I have a few
suggestion
- add alternative (like mini repo)
question
- does it work in Windows?
- how it is different from the alternative?
how it is different from the alternative?
I made this because I wanted to be able to change the command used for saving, and also so that I don't need to use any special commands to edit files in the first place. I just open the file I want to edit and if it needs sudo to edit, it prompts me.
does it work in Windows?
No. I don't use Windows so I'm not really interested in getting it to work.