ken@rochester.UUCP (Ipse dixit) (01/13/86)
ion time. I will feed myself to sh."; sh $0; kill $$) cat=/bin/cat echo=/bin/echo test=/bin/test defeditor=prompter draftfile=`mhpath +`/rndraft dotdir=${DOTDIR-${HOME-$LOGDIR}} $cat $1 > $draftfile if $test -f $dotdir/.signature; then $echo "--" >> $draftfile $cat $dotdir/.signature >> $draftfile fi exec comp -use -editor ${VISUAL-${EDITOR-$defeditor}} -file $draftfile That's all. Have fun. Ken -- UUCP: ..!{allegra,decvax,seismo}!rochester!ken ARPA: ken@rochester.arpa Snail: Comp. of Disp. Sci., U. of Roch., NY 14627. Voice: Ken!
ken@rochester.UUCP (Ipse dixit) (01/15/86)
[I fear you, line eater] I'm told the line eater munched the first posting. Let's try this once more... -- When a friend asked me how to save his outgoing responses to netnews I realized that MH could be made the mail interface to rn. Below is how. You may like to customize a bit. In .login or .cshrc: (sh users can translate) setenv MAILPOSTER "~/bin/rnmail %h" setenv MAILHEADER \ 'To: %T\ Subject: %(%i=^$?:Re: %S\ Fcc: +CC\ Newsgroups: %n\ In-Reply-To: %i)\ %(%[references]!=^$?References\: %[references]\ )Organization: %o\ \ ' In ~/bin/rnmail: (or whatever you choose to call it) #! /bin/sh export PATH || (echo "OOPS, this isn't sh. Desperation time. I will feed myself to sh."; sh $0; kill $$) cat=/bin/cat echo=/bin/echo test=/bin/test defeditor=prompter draftfile=`mhpath +`/rndraft dotdir=${DOTDIR-${HOME-$LOGDIR}} $cat $1 > $draftfile if $test -f $dotdir/.signature; then $echo "--" >> $draftfile $cat $dotdir/.signature >> $draftfile fi exec comp -use -editor ${VISUAL-${EDITOR-$defeditor}} -file $draftfile That's all. Have fun. Ken -- UUCP: ..!{allegra,decvax,seismo}!rochester!ken ARPA: ken@rochester.arpa Snail: Comp. of Disp. Sci., U. of Roch., NY 14627. Voice: Ken!
robert@erix.UUCP (Robert Virding) (01/17/86)
There's an easier way to do it which also allows using draft folders in MH. In .login (or whatever, .rninit is also a good place): setenv EMAILPOSTER "~/bin/mh comp -form %h" setenv EMAILHEADER \ 'To: %f\\n\ Cc: %L\\n\ Subject: Re: %S\\n\ In-Reply-To: Your message of %[date]\\n\ %i\\n\ %(%[references]!=^\$?References\\: %[references]\\n)\ Newsgroups: %n\\n-------\\n' ~/bin/mh is defined as: #! /bin/sh # A small shell script to run the MH-system. # Includes the mh command directory in the PATH # If a (mh) command is given this is run instead. # export PATH; PATH=/usr/new/mh:$PATH # the mh-system commands if [ $# = 0 ] then export PS1; PS1="MH> " # an informative prompt used by sh exec $SHELL # use the default shell else exec sh -c "$*" # run through shell fi This file is fine for running a subshell for MH as well. Robert Virding @ L M Ericsson, Stockholm UUCP: {decvax,philabs,seismo}!mcvax!enea!erix!robert