I use sudo quite a lot and get bored of typing my password in every time I use it. There is away around this, but only do this if no one else uses your machine or you don't leave your self logged in. Start a terminal and type:
% sudo visudoNow the only way to edit this file without playing around with chmod and so on is with visudo; this is a command used just to edit the /etc/sudoers file. It also does checks to make sure the formatting is correct. The following is the important part of the file. It basically says user 'root' can do all commands, group 'admin' can do all commands:
# User privilege specificationYou need to change this so it has NOPASSWD: before the last "all" for the admin group, so it looks like this:
root ALL=(ALL) ALL
%admin ALL=(ALL) ALL
# User privilege specificationYou can also add you username to the file:
root ALL=(ALL) ALL
%admin ALL=(ALL) NOPASSWD:ALL
# User privilege specificationNote: Those are tabs after the username and group name.
root ALL=(ALL) ALL
%admin ALL=(ALL) ALL
user_name ALL=(ALL) NOPASSWD:ALL
To write and save the file hit ESC (just to be safe) and then :wq, then hit Enter. This basically tells vi to write then quit; if you made an error in the file, it will tell you so and ask you want to do. If this happens, you should always revert and try again, it's a lot easier.
Of course you could always use "sudo tcsh" but I don't like being root when I'm playing around.
[Editor's note: visudo works like vi, so 'man vi' will explain how to use the editor. And please, take the security caution seriously. If someone else can get to your Mac, they will be able to execute commands as root without any authentication. Of course, once someone has physical access to the machine, most bets are off, but this makes it very easy for someone to do bad things to your machine if they so desire. Let me say it again ... this is a really bad thing to do from a security perspective! You'll need to decide if the risk is worth the few seconds of saved typing each time you sudo.]