[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: check if message is in a particular sequence?
From: |
Paul Fox |
Subject: |
Re: check if message is in a particular sequence? |
Date: |
Thu, 29 Apr 2021 16:16:39 -0400 |
ken wrote:
> >What's the fastest/easiest way to check if a particular message
> >is a member of a particular sequence?
> >
> >I thought I'd be able to compare the message number against the output
> >of "mark -list", but since sequences can be abbreviated with range
> >notation, that gets complicated quickly. For example, message 6 is in
> >the sequence todo, but it's hard to tell from this:
>
> You can get the expanded list of messages in a sequence by doing this:
>
> scan -format '%(msg)' sequence-name
>
> I think from there, it's easy. I do not know of a better way, but it
> wouldn't surprise me if someone came up with something better.
Thanks. Seems... overkill... to have to fire up a parsing language,
but it will definitely work.
Bob's solution, falls in the same (mostly good :-) category.
It also seems like mark(1) could do it. Currently it ignores its message
args if -list is given. It could be enhanced so that if message
args are given, then -list would only output sequence membership for
the given args.
...time passes...
I have a partial patch for mark which does what I described. Don't
know whether it's worth it or not.
paul
=----------------------
paul fox, pgf@foxharp.boston.ma.us (arlington, ma, where it's 47.5 degrees)
Re: check if message is in a particular sequence?, Ralph Corderoy, 2021/04/30