Re: [PATCH v4 2/7] strbuf: split out logic to humanise byte values
- From
Justin Tobler <jltobler@gmail.com>
- Date
- Dec 16, 2025, 19:39 UTC
- Message-ID
- <uyuorzpq6mqr2icszhzxswdyxpr3de4762yt5fynlpgmymovje@zzix54kgnwwm>
- In-Reply-To
- <xmqqqzsu2qxy.fsf@gitster.g>
On 25/12/17 03:59AM, Junio C Hamano wrote:
Show 18 quoted lines
> Justin Tobler <jltobler@gmail.com> writes:
>
> > +static void strbuf_humanise(struct strbuf *buf, off_t bytes, unsigned flags)
> > +{
> > + char *value;
> > + const char *unit;
> > +
> > + humanise_bytes(bytes, &value, &unit, flags);
> > +
> > + /*
> > + * TRANSLATORS: The first argument is the number string. The second
> > + * argument is the unit prefix string (i.e. "12.34 MiB/s").
> > + */
> > + strbuf_addf(buf, _("%s %s"), value, unit);
>
> "unit prefix string"? Prefix is something that comes before
> something else, but this one is at the end. Simply saying a "unit
> string" would probably be a sufficient fix, perhaps?Ya my bad, the prefix part would be just the Ki, Mi, etc. In this case it is the whole unit string. Saying "unit string" would be correct. I can send another version fixing this it if you would like.
Thanks for the review, -Justin