M README.md => README.md +9 -5
@@ 4,13 4,17 @@ This is a template for [beulogue](https://beulogue.ehret.me/).
## Installation
-Download a zip of the `multiple-languages` branch and extract it somewhere.
+Download the `multiple-languages` branch from GitHub:
-The zip is available on:
+```sh
+git clone -b multiple-languages https://github.com/SiegfriedEhret/beulogue-templates.git
+```
+
+Or from sourcehut:
-- [bitbucket](https://bitbucket.org/siegfriedehret/beulogue-templates/get/multiple-languages.zip)
-- [codeberg](https://codeberg.org/SiegfriedEhret/beulogue-templates/archive/multiple-languages.zip)
-- [github](https://github.com/SiegfriedEhret/beulogue-templates/archive/multiple-languages.zip)
+```sh
+git clone -b multiple-languages https://git.sr.ht/~siegfriedehret/beulogue-templates
+```
## What's inside ?
M public/en/feed.xml => public/en/feed.xml +1 -1
@@ 1,7 1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
<channel>
- <lastBuildDate>2019-08-01</lastBuildDate>
+ <lastBuildDate>2020-12-13</lastBuildDate>
<link>https://TODO</link>
<title>My awesome website</title>
<item>
M public/en/index.html => public/en/index.html +5 -2
@@ 24,10 24,12 @@
<h1>
My title
</h1>
-
+
<p>This content is from the <code>content/_index.md</code> file.</p>
+
</header>
+
<section>
<a href="/en/my-awesome-post.html">My awesome post</a>
@@ 35,5 37,6 @@
<p>A small description</p>
</section>
+
</body>
-</html>
+</html><
\ No newline at end of file
M public/en/my-awesome-post.html => public/en/my-awesome-post.html +7 -4
@@ 25,12 25,15 @@
My awesome post
</h1>
<div>
- <a href="/fr/my-awesome-post.html">fr</a>
+
<a href="/en/my-awesome-post.html">en</a>
+
+ <a href="/fr/my-awesome-post.html">fr</a>
+
</div>
-
+
<p>Yoohoo ! It works !</p>
+<p><a href="https://commons.wikimedia.org/wiki/File:Fujiview.jpg"><img src="/images/Fujiview.jpg" alt="Jmills74 at English Wikipedia [CC BY-SA 3.0 (http://creativecommons.org/licenses/by-sa/3.0/)], via Wikimedia Commons" /></a></p>
-<p><a href="https://commons.wikimedia.org/wiki/File:Fujiview.jpg"><img src="/images/Fujiview.jpg" alt="Jmills74 at English Wikipedia [CC BY-SA 3.0 (http://creativecommons.org/licenses/by-sa/3.0/)"/></a></p>
</body>
-</html>
+</html><
\ No newline at end of file
M public/fr/feed.xml => public/fr/feed.xml +1 -1
@@ 1,7 1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
<channel>
- <lastBuildDate>2019-08-01</lastBuildDate>
+ <lastBuildDate>2020-12-13</lastBuildDate>
<link>https://TODO</link>
<title>My awesome website</title>
<item>
M public/fr/index.html => public/fr/index.html +5 -2
@@ 24,10 24,12 @@
<h1>
Mon titre
</h1>
-
+
<p>Ce contenu vient du fichier <code>content/_index.fr.md</code>.</p>
+
</header>
+
<section>
<a href="/fr/my-awesome-post.html">Mon super billet</a>
@@ 35,5 37,6 @@
<p>Une petite description</p>
</section>
+
</body>
-</html>
+</html><
\ No newline at end of file
M public/fr/my-awesome-post.html => public/fr/my-awesome-post.html +7 -4
@@ 25,12 25,15 @@
Mon super billet
</h1>
<div>
- <a href="/fr/my-awesome-post.html">fr</a>
+
<a href="/en/my-awesome-post.html">en</a>
+
+ <a href="/fr/my-awesome-post.html">fr</a>
+
</div>
-
+
<p>Yoohoo ! Ça fonctionne !</p>
+<p><a href="https://commons.wikimedia.org/wiki/File:Fujiview.jpg"><img src="/images/Fujiview.jpg" alt="Jmills74 at English Wikipedia [CC BY-SA 3.0 (http://creativecommons.org/licenses/by-sa/3.0/)], via Wikimedia Commons" /></a></p>
-<p><a href="https://commons.wikimedia.org/wiki/File:Fujiview.jpg"><img src="/images/Fujiview.jpg" alt="Jmills74 at English Wikipedia [CC BY-SA 3.0 (http://creativecommons.org/licenses/by-sa/3.0/)"/></a></p>
</body>
-</html>
+</html><
\ No newline at end of file
M public/index.html => public/index.html +1 -1
@@ 1,1 1,1 @@
-<!DOCTYPE html><html><head><title>https://TODO/en</title><link rel="canonical" href="https://TODO/en"/><meta name="robots" content="noindex"/><meta charset="utf-8"/><meta http-equiv="refresh" content="0; url=https://TODO/en" /></head></html>>
\ No newline at end of file
+<!DOCTYPE html><html><head><title>/en</title><link rel="canonical" href="/en"/><meta name="robots" content="noindex"/><meta charset="utf-8"/><meta http-equiv="refresh" content="0; url=/en" /></head></html><
\ No newline at end of file
M templates/list.html => templates/list.html +7 -7
@@ 24,18 24,18 @@
<h1>
{{title}}
</h1>
-
- {{{content}}}
+
+ {{content | escape}}
</header>
- {{#pages}}
+ {% for page in pages %}
<section>
- <a href="{{url}}">{{title}}</a>
+ <a href="{{page.url}}">{{page.title}}</a>
- <div>{{dateFormatted}}</div>
+ <div>{{page.dateFormatted}}</div>
- <p>{{description}}</p>
+ <p>{{page.description}}</p>
</section>
- {{/pages}}
+ {% endfor %}
</body>
</html>
M templates/page.html => templates/page.html +5 -5
@@ 25,11 25,11 @@
{{ title }}
</h1>
<div>
- {{#multilang}}
- <a href="{{url}}">{{language}}</a>
- {{/multilang}}
+ {% for lang in multilang %}
+ <a href="{{lang.url}}">{{lang.language}}</a>
+ {% endfor %}
</div>
-
- {{{content}}}
+
+ {{content | escape}}
</body>
</html>