vim-suda
vim-suda copied to clipboard
Problem with -p flag
There is a problem with the -p flag (which is supposed to open multiple files in different tabs).
If I use nvim -p file1 file2 then everything works as expected if the files do not require superuser permission sto write to.
But is file1 requires superuser permissions the file2 is never opened in a separate tab.
If any file is passed as a command line argument that needs superuser permissions, the files passed after that argument are not opened in separate tabs.
It's not a problem with -p flag. It happens when you (the current user) don't have read permission for that file. When you open such files, you can see a "Permission Denied" message. To open such files, use SudaRead command, or run nvim using sudo.
Using sudo does solve the problem.
But the current user does have read permissions for the file. Hence the file opens using nvim without sudo, only that the files passed as an argument after that using the -p flag don't open in different tabs regardless of their permissions. The problem does not appear if this plugin is uninstalled.