On Thu 10 Feb 2022 at 20:26:57 (+0000), Joe wrote: > On Thu, 10 Feb 2022 11:11:01 -0500 rhkra...@gmail.com wrote: > > On Wednesday, February 09, 2022 06:08:16 AM Andrei POPESCU wrote: > > > I've switched to using sudo because it encourages me to use root > > > only when strictly required. > > > > That's a good idea, but I'll mention what I do -- I may have started > > before sudo existed (or, at least, before I knew about it). > > > > I use kde and keep several konsole (terminals) open, at on one, I > > open it as root and set the background to be a different color than > > the non-root konsole (a shade of yello). > > > > (Once you pick a color for the background (or any of variety of other > > user preferences), you can save those so, for example, every time I > > open a konsole as root, it gets those preferences. > > > > Just an additional note if you use mc: you can change the colours of the > mc window and save the changes, but when you close mc the previous > config file will overwrite the new one. What you have to do is to save > the config, then rename it from outside mc with mc still running. Close > mc, rename the new config file back to the original name, then it will > be used next time you start mc. > > A bit of a faff, which is why I don't change things often. But my > server is console-only, and I found mc to be an excellent file manager > and simple text editor for it. I also have different background colours > depending on whether it is opened with sudo or not.
Why not just set these five file permissions to readonly? .config/mc/{ini,panels.ini} .cache/mc/Tree{,.tmp} .local/share/mc/history The last might need to be owned by root (for normal users), or chattr +i if you run mc as root. (I don't.) > Yes, it's a dangerous beast as root, but what are you doing on a server > if not admin work (carefully)? Cheers, David.