# HG changeset patch # User Anton Shestakov # Date 1511267337 -28800 # Node ID e397f8585953b180bd4a1dfb000c7b38dc853958 # Parent 5cd6682b5a90f0bc096507b6010c442c89673840 hgweb: show changeset age in more places (gitweb and monoblue) mercurial.js has a process_dates() function that calculates relative age for a given date, it works for all elements with "age" css class. If those elements also have "date" css class, the original text is preserved and age is added at the end. This patch adds these two css classes in some pages in gitweb and monoblue that weren't already using this feature. diff -r 5cd6682b5a90 -r e397f8585953 mercurial/templates/gitweb/summary.tmpl --- a/mercurial/templates/gitweb/summary.tmpl Sun Nov 19 05:34:50 2017 +0100 +++ b/mercurial/templates/gitweb/summary.tmpl Tue Nov 21 20:28:57 2017 +0800 @@ -31,7 +31,7 @@ - +
description{desc}
owner{owner|obfuscate}
last change{lastchange|rfc822date}
last change{lastchange|rfc822date}
changes
diff -r 5cd6682b5a90 -r e397f8585953 mercurial/templates/monoblue/changeset.tmpl --- a/mercurial/templates/monoblue/changeset.tmpl Sun Nov 19 05:34:50 2017 +0100 +++ b/mercurial/templates/monoblue/changeset.tmpl Tue Nov 21 20:28:57 2017 +0800 @@ -44,7 +44,7 @@
author
{author|obfuscate}
date
-
{date|rfc822date}
+
{date|rfc822date}
{branch%changesetbranch}
changeset {rev}
{node|short}
diff -r 5cd6682b5a90 -r e397f8585953 mercurial/templates/monoblue/fileannotate.tmpl --- a/mercurial/templates/monoblue/fileannotate.tmpl Sun Nov 19 05:34:50 2017 +0100 +++ b/mercurial/templates/monoblue/fileannotate.tmpl Tue Nov 21 20:28:57 2017 +0800 @@ -42,7 +42,7 @@
author
{author|obfuscate}
date
-
{date|rfc822date}
+
{date|rfc822date}
{branch%filerevbranch}
changeset {rev}
{node|short}
diff -r 5cd6682b5a90 -r e397f8585953 mercurial/templates/monoblue/filerevision.tmpl --- a/mercurial/templates/monoblue/filerevision.tmpl Sun Nov 19 05:34:50 2017 +0100 +++ b/mercurial/templates/monoblue/filerevision.tmpl Tue Nov 21 20:28:57 2017 +0800 @@ -42,7 +42,7 @@
author
{author|obfuscate}
date
-
{date|rfc822date}
+
{date|rfc822date}
{branch%filerevbranch}
changeset {rev}
{node|short}
diff -r 5cd6682b5a90 -r e397f8585953 mercurial/templates/monoblue/summary.tmpl --- a/mercurial/templates/monoblue/summary.tmpl Sun Nov 19 05:34:50 2017 +0100 +++ b/mercurial/templates/monoblue/summary.tmpl Tue Nov 21 20:28:57 2017 +0800 @@ -34,7 +34,7 @@
owner
{owner|obfuscate}
last change
-
{lastchange|rfc822date}
+
{lastchange|rfc822date}

Changes

diff -r 5cd6682b5a90 -r e397f8585953 tests/test-hgweb-commands.t --- a/tests/test-hgweb-commands.t Sun Nov 19 05:34:50 2017 +0100 +++ b/tests/test-hgweb-commands.t Tue Nov 21 20:28:57 2017 +0800 @@ -1572,7 +1572,7 @@ - +
descriptionunknown
ownerFoo Bar <foo.bar@example.com>
last changeThu, 01 Jan 1970 00:00:00 +0000
last changeThu, 01 Jan 1970 00:00:00 +0000
changes