groff
[Top][All Lists]
Advanced

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

Re: [groff] improve a few terminal renderings of special characters


From: Ingo Schwarze
Subject: Re: [groff] improve a few terminal renderings of special characters
Date: Sat, 1 Sep 2018 15:01:13 +0200
User-agent: Mutt/1.8.0 (2017-02-23)

Hi John,

John Gardner wrote on Sat, Sep 01, 2018 at 10:26:40PM +1000:

> Ah I see, thanks. I might end up whitelisting sane systems (*BSD) and
> stupidly predictable ones (macOS), falling back to a JS-based
> implementation for all other cases.

I'd respectfully recommend the opposite approach:  Blacklist the (few)
systems where man -w is broken (if you don't want to test dynamically).
That way, you don't punish new systems.  Just because something has
a weird name we haven't heard yet doesn't mean it's insane and deleted
features that have been reliable since Unix v7 in 1979.

> It gets better (or worse). Here's what Solaris 11.3's `man -k grep` emits:
> 
> $ ~: man -k grep
> 
> 1. grep(1) /usr/share/man/man1/grep.1
> grep - search a file for a pattern

That's relatively recent:

   > uname -a
  SunOS unstable10s 5.10 Generic_150400-17 sun4v sparc 
SUNW,SPARC-Enterprise-T5220
   > man -k grep | head -n 2
  bzegrep         bzgrep (1)      - search possibly bzip2 compressed files for 
a regular expression
  bzfgrep         bzgrep (1)      - search possibly bzip2 compressed files for 
a regular expression

> ... which is probably the closest I've come to finding an equivalent to
> `man -k` on Solaris..

But it will only work on Solaris 11.  Neither on 9 nor 10.
Who knows about Illumos.

In general, if something works on Solaris 11, don't assume it's the same
on Solaris 10, and even less so on Solaris 9.  These systems differ a lot,
in particular with respect to questions of portability.

> I blame Oracle. Always blame Oracle.

I certainly don't like Oracle - but you shouldn't blame people for
evils predating any of their actions:

   > uname -a
  SunOS unstable9s 5.9 Generic_Virtual sun4u sparc SUNW,SPARC-Enterprise-T5220
   > man -w ls
  usage:  man [-] [-adFlrt] [-M path] [-T macro-package ] [ -s section ] name 
...
          man [-M path] -k keyword ...
          man [-M path] -f file ...

SunOS 5.9 was released in 2002, and Oracle aquired SUN in 2010.
So i fear for this particular bug, you have to blame good old SUN...

Yours,
  Ingo



reply via email to

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