[comp.mail.mh] Novice question about editing messages

bobd@bobd (Bob Dietrich) (04/10/91)

In article <m0jR1me-00007zC@ora.ora.com> jerry@ORA.ORA.COM (Jerry Peek) writes:
>BTW, one of the problems with having vi as the default for comp, forw,
>and dist is that you won't get the handy "prompter" editor for filling in
>the header -- for each component, you have to hit ESCAPE, move down, delete
>empty components you don't want and go into insert mode for others, etc.

What I do is use the prompter for initial message creation, and then use vi for
editing the message (if necessary). If I do edit the message, the unused fields
have already been deleted. This is accomplished with the following entries in my
.mh_profile:

	  prompter-next: vi
	  Editor: prompter

I'm not even sure that the second entry is necessary.

				Bob Dietrich
				Intel Corporation, Hillsboro, Oregon
				(503) 696-4270  (FAX: 696-4210)
		usenet:		bobd@bobd.intel.com
		  or		uunet!intelhf!ijf1!bobd
		  or		tektronix!ogccse!omepd!ijf1!bobd
		  or		tektronix!psu-cs!omepd!ijf1!bobd

jcav@quads.uchicago.edu (john cavallino) (04/11/91)

I'm just getting started with MH, so please be gentle with me if this has
an obvious answer.  I want to have repl always come up in my editor of
choice (which is vi, no flames please).  Right now I'm hitting control-D,
then responding 'edit vi' at the 'What now?' prompt.  Is there a better way?
Thanks much.

-- 
John Cavallino                      |     EMail: jcav@midway.uchicago.edu
University of Chicago Hospitals     |    USMail: 5841 S. Maryland Ave, Box 145
Office of Facilities Management     |            Chicago, IL  60637
"Opinions, my boy. Just opinions"   | Telephone: 312-702-6900

appel@xcf.Berkeley.EDU (Shannon D. Appel) (04/11/91)

In article <1991Apr10.230215.21858@midway.uchicago.edu> jcav@quads.uchicago.edu (john  cavallino) writes:
>I'm just getting started with MH, so please be gentle with me if this has
>an obvious answer.  I want to have repl always come up in my editor of
>choice (which is vi, no flames please).  Right now I'm hitting control-D,
You just need to modify your .mh_profile by adding the following line:

Editor: /usr/ucb/vi

For more info, type:

man mh-profile
 

jerry@ORA.ORA.COM (Jerry Peek) (04/11/91)

In <APPEL.91Apr10161658@sting.xcf.Berkeley.EDU>, Shannon D. Appel wrote:
> In article <1991Apr10.230215.21858@midway.uchicago.edu> jcav@quads.uchicago.edu (john  cavallino) writes:
> >... I want to have repl always come up in my editor of
> >choice (which is vi, no flames please)....
> 
> You just need to modify your .mh_profile by adding the following line:
> 
> Editor: /usr/ucb/vi

As explained in the mh-profile man page she mentioned, that line will set
the default editor for *all* MH commands to be vi.  In case you only want
repl to use vi, try this line instead:

	repl: -editor vi

BTW, one of the problems with having vi as the default for comp, forw,
and dist is that you won't get the handy "prompter" editor for filling in
the header -- for each component, you have to hit ESCAPE, move down, delete
empty components you don't want and go into insert mode for others, etc.
In the MH Nutshell Handbook, I showed a vi key map that helps a lot:
	map! ^N ^[/: $^[A
When you're in text-input mode in the message header and you type
control-N, it moves you to the end of the next empty header component
and puts you into text-input mode at the end of it.  (The ^[ are ESCAPE
characters, entered by typing control-V ESCAPE.)  I guess you could also
add another key map for "delete this line and take me to the next one."

--Jerry Peek, jerry@ora.com, uunet!ora!jerry

jcav@quads.uchicago.edu (john cavallino) (04/11/91)

Many thanks to all who responded.  Yes, I should have looked more closely
at the 'man' pages, where I would have seen the -editor parameter to repl
and others. (my face is red)  I appreciate your patience.

    JohnC

-- 
John Cavallino                      |     EMail: jcav@midway.uchicago.edu
University of Chicago Hospitals     |    USMail: 5841 S. Maryland Ave, Box 145
Office of Facilities Management     |            Chicago, IL  60637
"Opinions, my boy. Just opinions"   | Telephone: 312-702-6900

jbw@bigbird.bu.edu (Joe Wells) (04/13/91)

In article <APPEL.91Apr10161658@sting.xcf.Berkeley.EDU> appel@xcf.Berkeley.EDU (Shannon D. Appel) writes:

   You just need to modify your .mh_profile by adding the following line:

   Editor: /usr/ucb/vi

Can someone post the standard explanation for why this doesn't work with
GNU Emacs?  I've seen obscure references to this problem, but never the
full explanation.  And it's not in the FAQ yet.  :-(

Several of my users have complained about this not working.  Since I don't
use MH myself, I've never figured it out.  :-)

-- 
Joe Wells <jbw@cs.bu.edu>

jbw@bigbird.bu.edu (Joe Wells) (04/13/91)

In article <JBW.91Apr12135101@bigbird.bu.edu> jbw@bigbird.bu.edu (Joe Wells) writes:

   Can someone post the standard explanation for why this doesn't work with
   GNU Emacs?

I'd better add to this that this problem is encountered when using xmh.

-- 
Joe Wells <jbw@cs.bu.edu>

khera@cs.duke.edu (Vivek Khera) (04/13/91)

In article <JBW.91Apr12135101@bigbird.bu.edu> jbw@bigbird.bu.edu (Joe Wells) writes:

   In article <APPEL.91Apr10161658@sting.xcf.Berkeley.EDU> appel@xcf.Berkeley.EDU (Shannon D. Appel) writes:

      You just need to modify your .mh_profile by adding the following line:

      Editor: /usr/ucb/vi

   Can someone post the standard explanation for why this doesn't work with
   GNU Emacs?  I've seen obscure references to this problem, but never the
   full explanation.  And it's not in the FAQ yet.  :-(

   Several of my users have complained about this not working.  Since I don't
   use MH myself, I've never figured it out.  :-)

works for us.  SunOS 4.1, MH 6.7.1.  it has worked since MH 6.5 and
SunOS 3.5.  emacs version is 18.55.  we don't supply the full pathname
to emacs, just "Editor: emacs" works fine.  i've never heard that
this was a problem before (in 6 years of using MH...)

--
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Vick Khera, Gradual Student/Systems Guy   Department of Computer Science
ARPA:   khera@cs.duke.edu                 Duke University
UUCP:   ...!mcnc!duke!khera               Durham, NC 27706     (919) 660-6528

truesdel@nas.nasa.gov (David A. Truesdell) (04/13/91)

khera@cs.duke.edu (Vivek Khera) writes:

>In article <JBW.91Apr12135101@bigbird.bu.edu> jbw@bigbird.bu.edu (Joe Wells) writes:

>   Can someone post the standard explanation for why this doesn't work with
>   GNU Emacs?  I've seen obscure references to this problem, but never the
>   full explanation.  And it's not in the FAQ yet.  :-(

>   Several of my users have complained about this not working.  Since I don't
>   use MH myself, I've never figured it out.  :-)

>works for us.  SunOS 4.1, MH 6.7.1.  it has worked since MH 6.5 and
>SunOS 3.5.  emacs version is 18.55.  we don't supply the full pathname
>to emacs, just "Editor: emacs" works fine.  i've never heard that
>this was a problem before (in 6 years of using MH...)

You must have missed his followup, he mentioned that the users in
question were using Xmh.  From what I remember (I don't use it myself) Xmh
does not allow you to specify an alternate editor.  You're stuck with what
Xmh provides.
--
T.T.F.N.,
dave truesdell (truesdel@nas.nasa.gov)

Ita erat quando hic adventi.