Add GCW link to archived wiki pages, for the live version of said archived article.
This commit is contained in:
parent
7157757d43
commit
a9adf51453
@ -126,6 +126,7 @@ class ArchiveGenerator():
|
||||
|
||||
renderer.render_template_to_file("page", page_out, {
|
||||
"title": " - {}".format(page.title),
|
||||
"pagename": page.title,
|
||||
"page": page,
|
||||
"base": base,
|
||||
"text": rendered
|
||||
@ -143,6 +144,7 @@ class ArchiveGenerator():
|
||||
try:
|
||||
renderer.render_template_to_file("category", category_out, {
|
||||
"title": " - {}".format(category),
|
||||
"pagename": "Category:{}".format(category),
|
||||
"category": category,
|
||||
"pages": pages
|
||||
})
|
||||
@ -243,4 +245,4 @@ class TemplateRenderer():
|
||||
def render_template_to_file (self, template_name, out_file, data={}):
|
||||
with self.open_template(template_name) as template:
|
||||
with open(os.path.join(self.out_dir, out_file), "w") as out:
|
||||
out.write(chevron.render(template, data, self.partials_dir, self.extension))
|
||||
out.write(chevron.render(template, data, self.partials_dir, self.extension))
|
||||
|
@ -1,9 +1,9 @@
|
||||
{{>header}}
|
||||
{{>wiki_notice}}
|
||||
<h2>{{title}}</h2>
|
||||
<h2>{{pagename}}</h2>
|
||||
<ul>
|
||||
{{#pages}}
|
||||
<li><a href="{{url}}">{{title}}</a></li>
|
||||
{{/pages}}
|
||||
</ul>
|
||||
{{>footer}}
|
||||
{{>footer}}
|
||||
|
@ -1,5 +1,6 @@
|
||||
<div class="notice">
|
||||
<p>Glitch City Laboratories closed on 1 September 2020 (<a href="{{base}}../forums/board-2/thread-9114/page-0.html">announcement</a>). This is an <b>archived</b> copy of an article from Glitch City Laboratories wiki.</p>
|
||||
<p><b>A live version of this article is available at the <a href="https://glitchcity.wiki/">Glitch City Wiki</a> <a href="https://glitchcity.wiki/{{pagename}}">here</a>.</b></p>
|
||||
<p>You can join <a href="https://discord.com/invite/EA7jxJ6">Glitch City Research Institute</a> to ask questions or discuss current developments.</p>
|
||||
<p>You may also download the archive of the wiki in <a href="{{base}}../wiki.tar.gz">.tar.gz</a> or <a href="{{base}}../wiki.xml.gz">.xml.gz</a> formats.</p>
|
||||
</div>
|
||||
</div>
|
||||
|
Loading…
x
Reference in New Issue
Block a user