Chapter 9: Advanced e-mail (3 of 4) -- FTPMAIL

Chapter 9: Advanced e-mail (3 of 4) -- FTPMAIL


What if the file you want is not on one of these mail servers?  That's
where ftpmail comes in.  Run by Digital Equipment Corp. in California,
this service can connect to almost any  ftp  site in the world, get the
file you want and then mail it to you. Using it is fairly simple -- you
send an e-mail message to ftpmail that includes a series of commands
telling the system where to find the file you want and how to format it
to mail to you.
     Compose an e-mail message to

                ftpmail@decwrl.dec.com

     Leave the "subject:" line blank.  Inside the message, there are
several commands you can give.  The first line should be

                reply address

where "address" is your e-mail address. The next line should be

                connect host

where "host" is the system that has the file you want (for example:
wuarchive.wustl.edu). Other commands you should consider using are
"binary" (required for program files); "compress" (reduces the file size
for quicker transmission) and "uuencode" (which encodes the file so you
can do something with it when it arrives).  The last line of your message
should be the word "quit".
     Let's say you want a copy of the U.S. constitution.  Using archie,
you've found a file called, surprise, constitution, at the ftp site
archive.cis.ohio-state.edu, in the /pub/firearms/politics/rkba directory.
You'd send a message to ftpmail@decwrl.dec.com that looks like this:

                reply adamg@world.std.com
                connect archive.cis.ohio-state.edu
                binary
                compress
                uuencode
                get pub/firearms/politics/rkba/constitution
                quit

     When you get the file in your mailbox, use the above procedure for
copying it to a file.  Run it through uudecode.  Then type

                uncompress file.name

to make it usable.
     Since this was a text file, you could have changed the "binary" to
"ascii" and then eliminated the "uuencode" file.  For programs, though,
you'll want to keep these lines.