[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

mailing a file from lisp



    Date: Thu, 21 Nov 1991 18:19 EST
    From: starnet!bass!lakin@apple.com (Fred Lakin)

    Is there a function for mailing a file? It would be convenient if the
    header information could be included at the beginning of the file --
    like sendmail in unix, which manages to extract the To:, Subject:, etc
    fields from the front of a text file.

The function ZWEI:SEND-MESSAGE-STRING will mail a string; you could read
the contents of the file into a string and then send it.  The To address
is the first argument, and other header fields can be specified as
keyword arguents, e.g.

(zwei:send-message-string "barmar@think.com" "This is the body of the message"
			  :subject "test message"
			  :cc "slug@ai.sri.com")

As far as parsing the header, you're on your own there.  Unfortunately,
the only built-in functions that know how to parse a header are in
Zmail, which operates on editor buffers, not files or ordinary strings.

                                                barmar