suda.vim
🥪 An alternative sudo.vim for Vim and Neovim, limited support sudo in Windows (by lambdalisue)
vim-eunuch
eunuch.vim: Helpers for UNIX (by tpope)
suda.vim | vim-eunuch | |
---|---|---|
12 | 27 | |
656 | 1,783 | |
- | - | |
5.9 | 5.0 | |
12 days ago | 3 months ago | |
Vim Script | Vim Script | |
MIT License | - |
The number of mentions indicates the total number of mentions that we've tracked plus the number of user suggested alternatives.
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
suda.vim
Posts with mentions or reviews of suda.vim.
We have used some of these posts to build our list of alternatives
and similar projects. The last one was on 2023-01-11.
-
how can I use my config while in superuser mode?
Personally, I use suda.vim
-
Neovim says it's writing to some files when it doesn't
I've always tried using this plugin and doing SudaWrite, which doesn't work either.
-
don't you hate it when you edit a txt file in VI and then when you going to save it; says that you do not have permission?
In neovim this problem is solved by https://github.com/lambdalisue/suda.vim
-
sudowrite.lua: I wrote a small module that allows writing files as root
This emulates the well known sudo write trick (:w !sudo tee %), which unfortunately doesn't work in neovim. The code is mostly based on suda, except that it's fully written in lua and it's a small module that you can include in your config.
-
cmap alternative in lua ?
ye ol' sudo tee trick does not work in nvim afaik. Use this
- how edit root files in nvim lua??
-
Lua solution to writing a file using sudo
Neovim has numerous issues open about this and some are suggesting using suda.vim which works great. Personally I did not want to use a plugin just for this as all I wanted was to have a command that would replicate :w !sudo tee %.
-
How do you use sudo with neovim while keeping the config in init.lua?
You can see if suda.nvim fits your needs better.
-
YSK : Do not use 'sudo vim/nano/emacs..' to edit a file. Instead, set your $EDITOR and use sudoedit or sudo -e.
There's also Suda.vim
- Should I use vim or neovim?
vim-eunuch
Posts with mentions or reviews of vim-eunuch.
We have used some of these posts to build our list of alternatives
and similar projects. The last one was on 2023-06-24.
-
Automatically make files with shebang executable using autocommands
Honorable mention : vim-eunch has this feature plus many other convenience commands.
-
Best way to manipulate files inside neovim?
I use eunuch.vim mostly by executing :Rename or :Remove or :Move. I also use this plugin whenever I have to manipulate multiple files in the working directory using :Cfind -name '*.lua' -type f which puts all .lua files in the cwd in the quickfix list then doing something like :cfdo lua vim.lsp.buf.format() to format all files.
-
Why :find is so slow compared to vscode/sublime file search feature?
If you are avoiding vim plugins due to external, non-standard dependencies (e.g. fzf), then you might be pleased to know that some plugins can solve this problem with standard linux utilities, like :Cfind and :Lfind from tpope/vim-eunuch which use the find linux utility.
-
Which file explorer do you use?
I use vim-dirvish(you probably want to pair this with vim-enunch), it's a more minimal version of Netrw.
- How can I rename (case sensitive) a buffer and reopen it?
-
Renaming current file
Try vim-eunuch lua {'tpope/vim-eunuch', config = function () vim.cmd('cnoreabbrev rename Rename') --:rgb + to trigger end},
-
Problems Moving Files with Netrw
I use netrw but I do moving, renaming etc with vim-eunuch and have done for about ten years. It just works how you'd expect it to.
- what is your startup time?
-
What shell commands do you invoke a lot from vi?
You might want to look into :Delete from tpope's vim-eunuch, along with wrappers for mkdir, chmod, etc.
-
Move file open in window relative to files location?
I did try: 1. Using the vim file explorer move command: 1. It does not implement autocomplete 1. I cannot use the vim movement shortcuts to move in the path, so I need to use the arrow keys to get before the file name. (dealbreaker) 1. It does not rename the buffer 1. Using eunuch plugin Move command: https://github.com/tpope/vim-eunuch 1. Relative paths were dependent on doing a change directory command first. That is fine but bothersome. 1. Required me to write the filename manually if I used the autocomplete. I did not find an efficient way to paste the current file name (without the path) to a command argument. 1. All in all quite close but still not good enough for me.
What are some alternatives?
When comparing suda.vim and vim-eunuch you can also consider the following projects:
nvim-lua
nvim-tree.lua - A file explorer tree for neovim written in lua
octo.nvim - Edit and review GitHub issues and pull requests from the comfort of your favorite editor
barbar.nvim - The neovim tabline plugin.
neovim - Vim-fork focused on extensibility and usability
neo-tree.nvim - Neovim plugin to manage the file system and other tree like structures.
Vim - The official Vim repository
please - Really tiny sudo replacement
indentLine - A vim plugin to display the indention levels with thin vertical lines
notes - notes on the tools in my Unix/Linux toolbox, dotfiles, etc
vim-bbye - Delete buffers and close files in Vim without closing your windows or messing up your layout. Like Bclose.vim, but rewritten and well maintained.