I didn't notice you'd changed your submitter address.  Sorry about that.

-- 
Colin Watson                                       [[email protected]]
--- Begin Message ---
This message was created automatically by mail delivery software.

A message that you sent could not be delivered to one or more of its
recipients. This is a permanent error. The following address(es) failed:

  [email protected]
    SMTP error from remote mail server after RCPT TO:<[email protected]>:
    host mailin1.pacific.net.au [125.255.92.144]:
    550 5.1.1 <[email protected]>: Recipient address rejected:
    User unknown in virtual mailbox table

------ This is a copy of the message, including all the headers. ------

Return-path: <[email protected]>
Received: from 
3.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.4.1.b.e.2.f.f.b.0.b.8.0.1.0.0.2.ip6.arpa 
([2001:8b0:bff2:eb14::3] helo=riva.pelham.vpn.ucam.org)
        by a.painless.aa.net.uk with esmtps (TLSv1:AES128-SHA:128)
        (Exim 4.77)
        (envelope-from <[email protected]>)
        id 1XU3xE-0003LR-80; Wed, 17 Sep 2014 02:22:54 +0100
Received: from ns1.pelham.vpn.ucam.org ([172.20.153.2] helo=riva.ucam.org)
        by riva.pelham.vpn.ucam.org with esmtps 
(TLS1.2:DHE_RSA_AES_128_CBC_SHA1:128)
        (Exim 4.80)
        (envelope-from <[email protected]>)
        id 1XU3xC-0006Gj-N8; Wed, 17 Sep 2014 02:22:42 +0100
Date: Wed, 17 Sep 2014 02:22:41 +0100
From: Colin Watson <[email protected]>
To: Kevin Ryde <[email protected]>, [email protected]
Subject: Re: Bug#725157: man-db: /etc/mailcap of man page
Message-ID: <[email protected]>
References: <[email protected]>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <[email protected]>
User-Agent: Mutt/1.5.21 (2010-09-15)

Control: tag -1 pending

On Wed, Oct 02, 2013 at 04:15:01PM +1000, Kevin Ryde wrote:
> This is an idea for /etc/mailcap entries to run "man" on man pages.
> It allows for example
> 
>     see /usr/share/man/man1/man.1.gz
> 
> to display with man in either X or a tty, and also non-interactive like
> the following (though groff-base trumps this just yet ...)
> 
>     run-mailcap --action=cat /usr/share/man/man1/man.1.gz
> 
> The debian/man-db.mime file below can be taken by dh_installmime to
> install as /usr/lib/mime/packages/man-db.

Thanks!  I've applied this more or less verbatim, although I added
text/troff lines to match each of the application/x-troff-man lines, as
that seems to be what's needed with current file(1).

  
http://anonscm.debian.org/cgit/pkg-man-db/man-db.git/commit/?id=af63b7267097fc2a56607a31f3da8b3d5384a276

> /usr/lib/mime/packages/groff-base has a "copiousoutput" entry at
> priority=5 which is above what I propose here for man non-interactive,
> which means for now the groff bit has precedence in the --action=cat
> above.
> 
> I think the groff should be lower, but that will be a matter of groff
> and man-db cooperating.  The priority levels apply before the output
> style is considered, so usually any copiousoutput should be below any
> interactive viewing.

Well, I maintain groff as well, so send me patches.  I don't really use
mime-support much myself, so I'm happy to take guidance from those who
do.

> # "man -X" is only priority=6 since the gxditview it runs is rather
> # basic and perhaps something more sophisticated could be higher.  The
> # X entry is before the tty so the X is preferred under X.  (The tty
> # one still works there, in its declared needsterminal.)
> #
> # "-X100" seems to make better output than the default -X 75 dpi.
> # Dunno if that's some font dodginess or matching the X server's
> # advertised screen size resolution or something.
> #
> # "test -e gxditview" because it's in the "groff" package which is
> # only a Suggests of man-db and so may not be available.

Did you consider something like -Tpdf, which generally looks much nicer?
Is it possible to chain MIME handlers, so that we can say "this command
converts text/troff into image/pdf, and then you should go and work out
how to display image/pdf"?

> # "-Tascii" gives backspace overstriking, so use "col -b" to undo
> # that.  Piping to col also means "man" has a non-tty output and so
> # does not run its usual "more" etc pager, ensuring this entry is
> # non-interactive.
> #
> application/x-troff-man; /usr/bin/man -Tascii -l '%s' | col -b; 
> copiousoutput; description=Man page; priority=2

Why not -Tutf8 here?

Thanks,

-- 
Colin Watson                                       [[email protected]]



--- End Message ---

Reply via email to