rfg@paris.ics.uci.edu (Ronald Guilmette) (02/13/90)
Please excuse my total ignorance, but how can I get MH to append some set of say 3-4 lines at the end of every message that I send? I used to be able to do this by using a .signature file in BSD mail, but that doesn't seem to do it for MH. // rfg (This line inserted manually - what a pain!)
truesdel@sun217..nas.nasa.gov (David A. Truesdell) (02/13/90)
rfg@paris.ics.uci.edu (Ronald Guilmette) writes: >Please excuse my total ignorance, but how can I get MH to append some set >of say 3-4 lines at the end of every message that I send? > >I used to be able to do this by using a .signature file in BSD mail, but >that doesn't seem to do it for MH. > >// rfg (This line inserted manually - what a pain!) There are three ways that I can think of to do this. 1) Hack sendmail to append a users ".signature" file. (Actually, I thought I remembered seeing some code ifdef'd out, which would do this.) 2) Hack MH to do the same. (Yuck, to much work!) 3) Write a script which will construct various "comp" files for you. Which is what I did. I don't change my ".signature" file very often, so I don't consider having to do this an inconvience. My script: #!/bin/sh sig=${HOME}/.signature lib=${HOME}/.lib mail=${HOME}/Mail cat ${lib}/components ${sig} > ${mail}/components cat ${lib}/forwcomps ${sig} > ${mail}/forwcomps cat ${lib}/replcomps > ${mail}/replcomps cat ${lib}/forwfilter > ${mail}/forwfilter sed 's/^/:/' < ${sig} | cat ${lib}/replfilter - > ${mail}/replfilter T.T.F.N., dave truesdell (truesdel@prandtl.nas.nasa.gov) "Testing can show the presense of bugs, but not their absence." -- Dijkstra "Each new user of a new system uncovers a new class of bugs." -- Kernighan
jdpeek@RODAN.ACS.SYR.EDU (Jerry Peek) (02/13/90)
Ronald Guilmette <long-address@tut.cis.ohio-state.EDU> wrote: > Please excuse my total ignorance, but how can I get MH to append some set > of say 3-4 lines at the end of every message that I send? One easy way is to put the signature in your draft skeleton files, named "components", "replcomps" and "forwcomps" (don't do it to "distcomps"). If you don't already have these files in the MH directory on your account, you can copy the standard files from the system directory. Its name is something like /usr/local/lib/mh (it could be different on your system). For instance, make your "components" file look like this (but don't indent it): To: Cc: Subject: -------- --Jerry Peek; Syracuse University Academic Computing Services; Syracuse, NY jdpeek@rodan.acs.syr.edu, JDPEEK@SUNRISE.BITNET +1 315 443-3995 Then, tell "prompter" (the default program that MH uses to make a draft message) to let you type the body of your message before the signature lines. To do that, put this line in the .mh_profile file (in your home directory): prompter: -prepend Here's what will happen when you send a message: $ comp To: whoever Cc: Subject: Whatever --------Enter initial text This is the body of my message. I'm typing it on the terminal now. Blah, blah. Now I press RETURN and CONTROL-d; here comes the signature: --Jerry Peek; Syracuse University Academic Computing Services; Syracuse, NY jdpeek@rodan.acs.syr.edu, JDPEEK@SUNRISE.BITNET +1 315 443-3995 -------- What now? p $ There are other ways, but this one seems the easiest to me.
wisner@hayes.fai.alaska.edu (Bill Wisner) (02/13/90)
In <4891@amelia.nas.nasa.gov>, truesdel@sun217 (David A. Truesdell) writes: >1) Hack sendmail to append a users ".signature" file. (Actually, I thought I > remembered seeing some code ifdef'd out, which would do this.) No. NONONONO. A totally Evil and Rude solution. It is NOT the place of the delivery agent to handle signatures; that should be left to the user agent. Bleah. Bill Wisner <wisner@hayes.fai.alaska.edu> Gryphon Gang Fairbanks AK 99775