Handy dandy tip and something I'm posting because I routinely forget how to do - email yourself an attachment.
If you have a file you want to send (any file binary or otherwise) you just use the uuencode command.
uuencode filename1 filename2 | mail -s subject your@address
where filename1 is the name of a local file, and filename2 is the name you want to give to the attachment (these can be the same).
If you are running a script and want to send the output of the script you'd do that like so:
./scripts.sh | uuencode filename.txt | mail -s subject your@address
This was tested on OpenBSD, MacOS X, and CentOS. Though on CentOS I had to install the sharutils package in order to get uuencode.
Now, if you are unfamiliar with ctrl-z bg/fg etc.. you need to learn those. but the most interesting thing I learned was about the disown command.
linkslice-4:~ Bryan$ /usr/libexec/locate.updatedb &
linkslice-4:~ Bryan$ disown %%
linkslice-4:~ Bryan$ exit
Then in another shell note that it's still running.
Link: http://www.spacerogue.net/wordpress/?p=191
Interesting take on the old L0pht, symantec etc from one of the grand-daddies of the 90's era.