Mercurial > public > mercurial-scm > hg-stable
diff rust/rhg/src/blackbox.rs @ 48599:abbecb5cd6f3
blackbox: change year in logs to ISO 8601 format
AFAIK, year/month/day is not a format than anyone uses. It seems more
sensible to me to use ISO 8601, as that's standard and unambiguously
year-month-day.
Compatibility-wise, I think it's acceptable to change the default
format. It's most for human consumption. It's plausible that a few
tools parse this format, but it has already changed in the past (for
instance to add the current revision).
Differential Revision: https://phab.mercurial-scm.org/D12006
author | Valentin Gatien-Baron <valentin.gatienbaron@gmail.com> |
---|---|
date | Mon, 17 Jan 2022 21:20:46 -0500 |
parents | 7284b524b441 |
children | 137a93125902 |
line wrap: on
line diff
--- a/rust/rhg/src/blackbox.rs Mon Jan 17 21:00:33 2022 -0500 +++ b/rust/rhg/src/blackbox.rs Mon Jan 17 21:20:46 2022 -0500 @@ -13,7 +13,7 @@ const DEFAULT_MAX_FILES: u32 = 7; // Python does not support %.3f, only %f -const DEFAULT_DATE_FORMAT: &str = "%Y/%m/%d %H:%M:%S%.3f"; +const DEFAULT_DATE_FORMAT: &str = "%Y-%m-%d %H:%M:%S%.3f"; type DateTime = chrono::DateTime<chrono::Local>;