aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAdrian Kummerlaender2014-10-20 19:59:55 +0200
committerAdrian Kummerlaender2014-10-20 19:59:55 +0200
commit41d175738c3f11579ad4033d0b2fc9f94b751d6f (patch)
tree061b15c315fd679b6fde666e4d9a3737de7bdde2
parent14ee0d2e8bba56e24a28e9a824731fddc9b2b7a5 (diff)
downloadOverview-41d175738c3f11579ad4033d0b2fc9f94b751d6f.tar
Overview-41d175738c3f11579ad4033d0b2fc9f94b751d6f.tar.gz
Overview-41d175738c3f11579ad4033d0b2fc9f94b751d6f.tar.bz2
Overview-41d175738c3f11579ad4033d0b2fc9f94b751d6f.tar.lz
Overview-41d175738c3f11579ad4033d0b2fc9f94b751d6f.tar.xz
Overview-41d175738c3f11579ad4033d0b2fc9f94b751d6f.tar.zst
Overview-41d175738c3f11579ad4033d0b2fc9f94b751d6f.zip
Expanded timeline transformation to include repository and commit links
* added `meta.xml` source document defining the mirror urls to be linked to
-rw-r--r--source/00_content/meta.xml6
-rw-r--r--source/99_result/stream.xsl25
2 files changed, 29 insertions, 2 deletions
diff --git a/source/00_content/meta.xml b/source/00_content/meta.xml
new file mode 100644
index 0000000..b802002
--- /dev/null
+++ b/source/00_content/meta.xml
@@ -0,0 +1,6 @@
+<datasource>
+ <mirror>
+ <repository>http://code.kummerlaender.eu</repository>
+ <commit>commit/?id=</commit>
+ </mirror>
+</datasource>
diff --git a/source/99_result/stream.xsl b/source/99_result/stream.xsl
index 7cb695d..5c037d6 100644
--- a/source/99_result/stream.xsl
+++ b/source/99_result/stream.xsl
@@ -12,6 +12,7 @@
<xsl:variable name="meta">
<datasource type="main" mode="iterate" source="04_meta/paginated_timeline.xml" target="page"/>
<datasource type="support" mode="full" source="02_augment/formatted_commits.xml" target="commits"/>
+ <datasource type="support" mode="full" source="00_content/meta.xml" target="meta"/>
<target mode="xpath" value="concat($datasource/page/entry/@index, '/index.html')"/>
</xsl:variable>
@@ -36,9 +37,29 @@
<xsl:text> at </xsl:text>
<xsl:value-of select="$commit/date/@time"/>
<xsl:text> | </xsl:text>
- <xsl:value-of select="$repository"/>
+ <a>
+ <xsl:attribute name="href">
+ <xsl:value-of select="concat(
+ $root/meta/mirror/repository, '/',
+ $repository
+ )"/>
+ </xsl:attribute>
+
+ <xsl:value-of select="$repository"/>
+ </a>
<xsl:text> | </xsl:text>
- <xsl:value-of select="$commit/@hash"/>
+ <a>
+ <xsl:attribute name="href">
+ <xsl:value-of select="concat(
+ $root/meta/mirror/repository, '/',
+ $repository, '/',
+ $root/meta/mirror/commit,
+ $commit/@hash
+ )"/>
+ </xsl:attribute>
+
+ <xsl:value-of select="$commit/@hash"/>
+ </a>
</p>
<xsl:apply-templates select="$commit/message/*[name() != 'h1']" mode="xhtml"/>