Go to the previous, next section.

The File's in the Mail

E-mail by itself is a powerful tool, and by now you may be sending e-mail messages all over the place. You might even be on a mailing list or two. But there is a lot more to e-mail than just sending messages. If your host system does not have access to ftp, or it doesn't have access to every ftp site on the Net, you can have programs and files sent right to your mailbox. And using some simple techniques, you can use e-mail to send data files such as spreadsheets, or even whole programs, to friends and colleagues around the world.

A key to both is a set of programs known as encoders and decoders. For all its basic power, Net e-mail has a big problem: it can't handle graphics characters or the control codes found in even the simplest of computer programs. Encoders however, can translate these into forms usable in e-mail, while decoders turn them back into a form that you can actually use. If you are using a Unix-based host system, chances are it already has an encoder and decoder online that you can use. These programs will also let you use programs posted in several Usenet newsgroups, such as comp.binaries.ibm.pc.

If both you and your intended recipient communicate via Unix-based host systems, then it's pretty easy, because almost all Unix host systems will have encoder/decoder programs online.

First, upload the file you want to send to your friend to your host site. Ask your system administrator how to upload a file to your name or "home" directory. Then type

uuencode file file >file.uu

and hit enter. "File" is the name of the file you want to prepare for mailing, and yes, you have to type the name twice! The > is a Unix command that tells the system to call the "encoded" file "file.uu" (you could actually call it anything you want).

Now to get it into a mail message. The quick and dirty way is to type

mail friend

where "friend" is your friend's address. At the subject line, tell her the name of the enclosed file. When you get the blank line, type

~r file.uu

or whatever you called the file, and hit enter. (on some systems, the `~' may not work; if so, ask your system administrator what to use). This inserts the file into your mail message. Hit control-D, and your file is on its way!

On the other end, when your friend goes into his mailbox, she should transfer it to her home directory. Then your friend should type

uudecode file.name

and hit enter. This creates a new file in her name directory with whatever name you originally gave it. She can then download it to her own computer. Before she can actually use it, though, she'll have to open it up with a text processor and delete the mail header that has been "stamped" on it. If you use a mailer program that automatically appends a "signature," tell her about that so she can delete that as well.

Go to the previous, next section.