Re: [PATCH 03/10] i18n: mark relative dates for translation
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Apr 24, 2012, 20:04 UTC
- Message-ID
- <xmqqd36wgam5.fsf@junio.mtv.corp.google.com>
- In-Reply-To
- <1335184230-8870-4-git-send-email-pclouds@gmail.com>
Nguyễn Thái Ngọc Duy <pclouds@gmail.com> writes:
Show 5 quoted lines
> From: Jonathan Nieder <jrnieder@gmail.com> > > Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> > Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> > ---
Looks nicely done ;-)
Show 11 quoted lines
> /* Give years and months for 5 years or so */
> if (diff < 1825) {
> ...
> }
> /* Otherwise, just years. Centuries is probably overkill. */
> - snprintf(timebuf, timebuf_size, "%lu years ago", (diff + 183) / 365);
> - return timebuf;
> + strbuf_addf(timebuf,
> + Q_("%lu year ago", "%lu years ago", (diff + 183) / 365),
> + (diff + 183) / 365);
> }This is just a tangent, but could we possibly come here and say "1 year ago"?