Stop Using sudo vim IMMEDIATELY and Do This Instead (sudoedit) @EricMurphyxyz
Stop Using sudo vim IMMEDIATELY and Do This Instead (sudoedit)  @EricMurphyxyz
Uploaded October 2022 | Updated November 2026, 3 hours ago
Let me guess. You were going to edit a system file and typed in SUDO VIM like usual, right? In this video, I'll go over why you don't want to do that and what you should be using instead (sudoedit). Not only so you can keep your nice .vimrc file that you worked so hard on but for security reasons as well. Plus, if you want even more options, I'll show you some tricks to write a read-only file with Vim anyway...

How to install and manage Vim plugins: youtube.com/watch?v=MztQMLyyCnU
Why you should never run "sudo npm": youtube.com/watch?v=aFrR56sqC_A

Vim "write with sudo" shortcut: stackoverflow.com/a/7078429
suda.vim GitHub: github.com/lambdalisue/suda.vim

Watch my videos on Odysee: odysee.com/@ericnmurphy
My website: https://ericmurphy.xyz
My GitHub: github.com/ericmurphyxyz

0:00 Intro
0:51 sudo vim not using your vimrc
1:34 Security issues with sudo vim
2:22 Using sudoedit
4:02 Setting the editor sudoedit uses
5:14 Alternatives to sudoedit
5:36 Saving a read-only file with w !sudo tee %
6:31 Using the suda.vim plugin to write to read-only files
6:41 Conclusion
Stop Using sudo vim IMMEDIATELY and Do This Instead (sudoedit)Why you (probably) shouldnt use an Arch Linux install scriptFree and Open-Source...Chess?Why you should NEVER use GoDaddy...How to make your sites look good without 1 million slow Google fontsHow to Force Close Unresponsive Programs in LinuxMaking Better Websites with Hugo!Why Im NEVER Joining Mastodon.How to deploy static sites to a VPS (the easy way)How to protect your online privacy without going insaneHow to Get All Your Favorite VSCode Features in VimHow to Install and Manage Vim Plugins (The Easy Way)
Eric Murphy |

Stop Using "sudo vim" IMMEDIATELY and Do This Instead (sudoedit)

SHARE TO X SHARE TO REDDIT SHARE TO FACEBOOK WALLPAPER