The original post refers to a script/utility I wrote for use on printjobs submitted via Samba by Windows clients. The utility is available from by website <http://www.pobox.com/~agreene/downloads/>.
Below is the response I sent directly to the original poster. --Tony ----- Forwarded message from "Anthony E. Greene" <[EMAIL PROTECTED]> ----- From: "Anthony E. Greene" <[EMAIL PROTECTED]> To: Mikevl <[EMAIL PROTECTED]> Date: Tue, 3 Dec 2002 09:51:34 -0500 Subject: Re: How can I create PDFs under Linux? Print into PDF (like with Acrobat)? On 03-Dec-2002/21:56 +1300, Mikevl <[EMAIL PROTECTED]> wrote: >Can this be modified to email from Linux? > >This would be useful for printing man pages > >i.e. man -t sed > /usr/local/bin/print2pdf %s %m %U >bur this doesn't seem to work. You have to adapt the Samba usage to command line usage. Samba writes the Postscript to a temp file and passes the name of that file as the first argument on the command line. The second argument is the machine name that should be used as the target of a WinPopup-style message to tell the user that the printjob is done. Most Linux boxes are not setup to accept these messages. You can pass the hostname of the box anyway and the WinPopup attempt will fail silently, with no ill effects on the rest of the script. The third argument is the username of the use who owns the printjob. This string is used to find an email address for delivery of the PDF. In my environment, the string is used as part of an LDAP lookup because my users do not receive mail on my machine, and I do not maintain email forwarding aliases for them. Instead, their aliases are maintained on an LDAP server. On your machine, it is likely that the username matches an alias or a real user on the Samba box. If so, then you should set "$useldap = 0" in the print2pdf script. Taking all of the above into account, you should use the following commands: tmpfile=/tmp/manpage.tmp man -t sed > $tmpfile /usr/local/bin/print2pdf $tmpfile localhost $LOGNAME rm $tmpfile Tony -- Anthony E. Greene <mailto:[EMAIL PROTECTED]> OpenPGP Key: 0x6C94239D/7B3D BD7D 7D91 1B44 BA26 C484 A42A 60DD 6C94 239D AOL/Yahoo Chat: TonyG05 HomePage: <http://www.pobox.com/~agreene/> Linux: the choice of a GNU Generation. <http://www.linux.org/> ----- End forwarded message ----- -- redhat-list mailing list unsubscribe mailto:[EMAIL PROTECTED]?subject=unsubscribe https://listman.redhat.com/mailman/listinfo/redhat-list