[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Nmh-workers] new marker format broke test suite
From: |
Paul Fox |
Subject: |
Re: [Nmh-workers] new marker format broke test suite |
Date: |
Tue, 06 May 2014 11:50:24 -0400 |
ken wrote:
> >in particular, the old marker lines included the size of the part
> >being shown:
> > part text/plain 18K
> >and the new marker lines do not:
> > [ part - text/plain - ]
> >
> >as far as i can tell, the size of the part isn't currently available
> >at all via mh-format, let alone in the "human friendly" format that
> >comes from list_content(). (list_content() produces the format you'll
> >see if you run mhlist on the message.)
>
> So, there is a function called %(size) which means "the size of the
> message". That's also passed in to the dat[] array, just like %(unseen)
> is. Seems like you could do the same magic that mhlistsbr.c does (which
> is call the size function for the part if it's available, otherwise
> calculate it based on file offsets).
oh, nice. thanks. done.
>
> >i have a patch ready to push to master to make the tests match the
> >current code. what i'm wondering, though, is whether folks instead
> >think that the mhshow marker format should grow the ability to produce
> >the previous output exactly (and if so, that output would likely
> >become the new default).
>
> Well, you know ... actually, maybe it should get that ability. I think
> having the size is useful. But ... do we add metric prefixes to that?
> Doing that directly in mh-format looks like it's doable, but it would be
> awful. It would probably make more sense to make a new format function
> that would take an integer as input and output a string that contained
> the number with the appropriate metric prefix appended. That way you
> could do:
>
> %(metric(size))
>
> And that could be usable in scan formats and the like. Not in love with
> the function name, so other suggestions are welcome.
>
> If you're not up for coding that, I could get to it, but it might be
> a few days before it would be done.
i'll take a look at it.
paul
----------------------
paul fox, address@hidden (arlington, ma, where it's 59.0 degrees)
- Re: [Nmh-workers] new marker format broke test suite, Paul Fox, 2014/05/05
- Re: [Nmh-workers] new marker format broke test suite, Ken Hornstein, 2014/05/06
- Re: [Nmh-workers] new marker format broke test suite,
Paul Fox <=
- Re: [Nmh-workers] new marker format broke test suite, Paul Fox, 2014/05/06
- Re: [Nmh-workers] new marker format broke test suite, Ken Hornstein, 2014/05/06
- Re: [Nmh-workers] new marker format broke test suite, Paul Fox, 2014/05/06
- Re: [Nmh-workers] new marker format broke test suite, Ken Hornstein, 2014/05/06
- Re: [Nmh-workers] new marker format broke test suite, Paul Fox, 2014/05/06
- Re: [Nmh-workers] new marker format broke test suite, Ken Hornstein, 2014/05/06
- Re: [Nmh-workers] new marker format broke test suite, Paul Fox, 2014/05/06