Re: [PATCH 1/3] chainlint: sidestep impoverished macOS "terminfo"

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

 



On 2022-11-10 at 22:36:14, Eric Sunshine wrote:
> On Thu, Nov 10, 2022 at 5:21 PM brian m. carlson
> <sandals@xxxxxxxxxxxxxxxxxxxx> wrote:
> > On 2022-11-10 at 03:37:16, Eric Sunshine wrote:
> > > I notice that the iTerm2 FAQ also recommends "xterm-new" on macOS, and
> > > that one lacks "dim", as well on my machine. So, it seems that it
> > > should be special-cased too.
> > >
> > > Taking all the above into account, perhaps this regex?
> > >
> > >     /xterm|xterm-.*color|xterm-new|nsterm/
> >
> > Maybe this, then?
> >
> > /(xterm|nsterm)(-(256color|direct))?|xterm-new/
> >
> > That matches the three special variants of each one here plus xterm-new.
> 
> I was thinking of targeting xterm-16color too, not just
> xterm-256color, just to cover bases a bit better.

Sure, that seems like a good idea.  I know that was popular for a time,
although I feel like it's maybe less popular today with more colour
options.

> I also don't mind manually spelling out the regex:
> 
>     /xterm|xterm-\d+color|xterm-new|xterm-direct|nsterm|nsterm-\d+color|nsterm-direct/
> 
> for simplicity's sake; sure it's verbose, but it's also dead-easy for
> people to understand and extend in the future if necessary.

Simplicity is nice.  I think that seems like a good pattern.
-- 
brian m. carlson (he/him or they/them)
Toronto, Ontario, CA

Attachment: signature.asc
Description: PGP signature


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux