Re: [PATCH v3 5/6] date: document and test "raw-local" mode
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Jul 27, 2016, 19:49 UTC
- Message-ID
- <xmqq37mux3mz.fsf@gitster.mtv.corp.google.com>
- In-Reply-To
- <20160727134441.GB14928@sigill.intra.peff.net>
Jeff King <peff@peff.net> writes:
> +e.g. ``2 hours ago''. The `-local` option has no effect for > +`--date=relative`.
Good.
Show 9 quoted lines
> @@ -746,7 +746,10 @@ format, often found in email messages. > + > `--date=short` shows only the date, but not the time, in `YYYY-MM-DD` format. > + > -`--date=raw` shows the date in the internal raw Git format `%s %z` format. > +`--date=raw` shows the date in the internal raw Git format `%s %z` > +format. Note that the `-local` option does not affect the > +seconds-since-epoch value (which is always measured in UTC), but does > +switch the accompanying timezone value.
Not your fault, but "internal raw Git format X format" sounds a bit clunky.
shows the date in `%s %z` format (seconds since 1970-01-01
00:00:00 UTC, space, timezone as sign and four digits)
or something like that? I suspect %s is not a POSIX-kosher strftime
conversion specifier, so from that point of view, perhaps making the
text the authoritative description and demote the format string as a
comment to help those who know strfmt, i.e. shows the date as seconds since 1970-01-01 00:00:00 UTC,
space, timezone as sign and four digits (i.e. as if the
timestamp were formatted with `strftime("%s %z")`).perhaps?