I've developed a bad habit of constantly sudoing to root. I was wondering if its possible to create an alias that prevents straight sudo but allows sudo -u. Or possibly echoes a warning when using sudo?
closed as not constructive by MDMarra, John Gardeniers, Magellan, MadHatter, Scott Pack Nov 27 '12 at 13:48
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.If this question can be reworded to fit the rules in the help center, please edit the question.
This is a people problem, but...
By default sudo gives a warning when asking for your password ("with great power comes great responsibility etc etc")
You can use a custom sudo lecture file to setup a custom warning.