[Top][All Lists]

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

Re: [Nmh-workers] Getting mhshow to invoke my browser for html parts

From: Ken Hornstein
Subject: Re: [Nmh-workers] Getting mhshow to invoke my browser for html parts
Date: Mon, 02 Jun 2014 10:41:25 -0400

>I suppose the dialog between the two of you has answered this question, but I
>can't figure out what the answer was. If the answer depends on decisions you
>have made to change nmh defaults, assume that that has happened.
>How do I get mhshow to use my current browser for html parts? If there is no
>way for nmh to know determine my current browser, how do I tell that to nmh?

The changes to mhshow were discussed before, but I don't think everyone quite
understood the implications.  Let me explain in greater detail.

For 1.6, the default behavior for mhshow is:

1) text parts are to be processed with utilities that output the text on
   standard out.  Before the processing of each part was free to do whatever
   it wanted, which in really old versions of MH did things like invoking
   an xterm.
2) Everything is run under one pager.  Previously each part was responsible
   for invoking the pager.

I would like to emphasize these are the defaults.  You can change them
back to the previous (IMHO, sucky) behavior).  So, you want to change
1).  That's easy enough; just arrange for an appropriate entry for
your your mhshow-show-text/html entry in your .mh_profile.  What's
an "appropriate entry" look like?  No idea!  Well, I mean, it will probably
look something like:

mhshow-show-text/html: launch-my-browser %F

The man page for mhshow has more details.  I don't know what launch-my-browser
is supposed to be for your system; for MacOS X it would be a command called
"open", but someone else can give you advice there.

Now, there is a wrinkle.  mhshow, by default, is expecting something to
appear on stdout.  It doesn't really NEED anything to appear on stdout, but
less will wait until everything has closed stdout (usually by exiting).
So if your "launch-my-browser" program is long-running, less will never
complete because it's waiting for it to finish.  You could fix that by
doing something like:

mhshow-show-text/html: launch-my-browser %F > /dev/null

So less isn't waiting for it to finish.  You could also use the -noconcat
option, which reverts to the old behavior where the program used to process
each part was responsible for handling the pager.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]