4 ms·
On my severs I often use “sudo -s“ in a separate tmux window. I've changed my PS1 to give me a red prompt for root. Over the years I never had a situation where
by mh-cx 10y ago
On my severs I often use “sudo -s“ in a separate tmux window. I've changed my PS1 to give me a red prompt for root. Over the years I never had a situation where I accidentally did something stupid as root.
- _lce0 10y agoIt is so good to have visual clues. I do something similar, using.. red = root yellow = others (or ssh) green = me Plus when I'm SSH'ing to a remote box, it usually defaults to white prompt
- dllthomas 10y agoI check in PROMPT_COMMAND whether the current terminal can sudo without a password and add a colored note to my prompt if so.