From d5f793bcd9f47392ee6e61c27f65fa85cbcc5176 Mon Sep 17 00:00:00 2001 From: Florian Dold Date: Mon, 30 Jan 2017 21:33:46 +0100 Subject: remove more ssi --- about.html.j2 | 26 +++++++++++++------------- citizens.html.j2 | 8 ++++---- common/footer.inc.j2 | 7 ------- common/header.j2.inc | 12 ++++++------ common/navigation.j2.inc | 22 +++++++++++----------- developers.html.j2 | 6 +++--- financial-news.html.j2 | 6 +++--- governments.html.j2 | 6 +++--- index.html.j2 | 2 +- investors.html.j2 | 6 +++--- locale/de/LC_MESSAGES/messages.po | 25 +++++++++++++------------ locale/en/LC_MESSAGES/messages.po | 25 +++++++++++++------------ locale/es/LC_MESSAGES/messages.po | 25 +++++++++++++------------ locale/fr/LC_MESSAGES/messages.po | 25 +++++++++++++------------ locale/it/LC_MESSAGES/messages.po | 25 +++++++++++++------------ merchants.html.j2 | 6 +++--- news.html.j2 | 6 +++--- template.py | 15 ++++++++++++--- template.sh | 2 +- wallet.html.j2 | 6 +++--- 20 files changed, 134 insertions(+), 127 deletions(-) delete mode 100644 common/footer.inc.j2 diff --git a/about.html.j2 b/about.html.j2 index 846046ff..7159fcaf 100644 --- a/about.html.j2 +++ b/about.html.j2 @@ -4,11 +4,11 @@ {{ _("GNU Taler") }} - {{ _("About us") }} - + {% include "common/header.j2.inc" %}
- + {% include "common/navigation.j2.inc" %}

{{ _("About us") }}

@@ -18,58 +18,58 @@

Dr. Christian Grothoff

- Christian Grothoff + Christian Grothoff

{{ _("GNU maintainer. Network security & privacy researcher. Software architect.") }}

Leon Schumacher

- Leon Schumacher + Leon Schumacher

{{ _("Entrepreneur, Investor, Fortune 100 CIO, IT company director in different industries, ….") }}

Robert Goldmann

- Robert Goldmann + Robert Goldmann

{{ _("CFO") }}

Dr. Jeffrey Burdges

- Jeffrey Burdges + Jeffrey Burdges

{{ _("Applied cryptography. Contact to W3c & Tor.") }}

Dr. Cristina Onete

- Cristina Onete + Cristina Onete

{{ _("Theoretical foundations.") }}

Dr. Richard M. Stallman

- Richard Stallman + Richard Stallman

{{ _("Founder of the GNU project. Ethical guidance and licensing.") }}

Sree Harsha Totakura

- Sree Harsha Totakura + Sree Harsha Totakura

{{ _("PhD Student, TU Munich. Currently teaching.") }}

Florian Dold

- Florian Dold + Florian Dold

{{ _("PhD Student, Inria..") }}

Marcello Stanisci

- Marcello Stanisci + Marcello Stanisci

{{ _("Software engineer.") }}

Dr. Nana Karlstetter

- Nana Karlstetter + Nana Karlstetter

{{ _("Sustainable business development.") }}

@@ -115,7 +115,7 @@

{{ _("Software engineer. Works on Android wallet.") }}

- + {% include "common/footer.j2.inc" %}
diff --git a/citizens.html.j2 b/citizens.html.j2 index 0f708f8b..0f5964b7 100644 --- a/citizens.html.j2 +++ b/citizens.html.j2 @@ -4,11 +4,11 @@ {{ _("GNU Taler") }} - {{ _("Citizens") }} - + {% include "common/header.j2.inc" %}
- + {% include "common/navigation.j2.inc" %}

{{ _("Advantages for citizens") }}

@@ -65,7 +65,7 @@ ") }}

- customer perspective + customer perspective
  1. {{ _("The customer selects an exchange (i.e. by visiting the respective website or selecting from a list of exchanges in the @@ -98,7 +98,7 @@

- + {% include "common/footer.j2.inc" %}
diff --git a/common/footer.inc.j2 b/common/footer.inc.j2 deleted file mode 100644 index 6320e0d6..00000000 --- a/common/footer.inc.j2 +++ /dev/null @@ -1,7 +0,0 @@ - - diff --git a/common/header.j2.inc b/common/header.j2.inc index b71482d9..3087d23e 100644 --- a/common/header.j2.inc +++ b/common/header.j2.inc @@ -30,14 +30,14 @@ - + - - + + - - - + + + + {% include "common/header.j2.inc" %}
- + {% include "common/navigation.j2.inc" %}

{{ _("Taler for developers") }}

@@ -213,7 +213,7 @@

- + {% include "common/footer.j2.inc" %}:w
diff --git a/financial-news.html.j2 b/financial-news.html.j2 index e424db87..878b1d9d 100644 --- a/financial-news.html.j2 +++ b/financial-news.html.j2 @@ -4,11 +4,11 @@ {{ _("GNU Taler") }} - {{ _("Financial News") }} - + {% include "common/header.j2.inc" %}
- + {% include "common/navigation.j2.inc" %}

{{ _("Financial News") }}

@@ -200,7 +200,7 @@

Source

- + {% include "common/footer.j2.inc" %}
diff --git a/governments.html.j2 b/governments.html.j2 index 8a924e7d..0d48e455 100644 --- a/governments.html.j2 +++ b/governments.html.j2 @@ -4,11 +4,11 @@ {{ _("GNU Taler") }} - {{ _("Governments") }} - + {% include "common/header.j2.inc" %}
- + {% include "common/navigation.j2.inc" %}

{{ _("Advantages for governments") }}

@@ -98,7 +98,7 @@

- + {% include "common/footer.j2.inc" %}
diff --git a/index.html.j2 b/index.html.j2 index 34c30d3b..58a869c8 100644 --- a/index.html.j2 +++ b/index.html.j2 @@ -1,5 +1,5 @@ - + {{ _("GNU Taler") }} diff --git a/investors.html.j2 b/investors.html.j2 index 13bd3f61..2de7a57f 100644 --- a/investors.html.j2 +++ b/investors.html.j2 @@ -4,11 +4,11 @@ {{ _("GNU Taler") }} - {{ _("Investors") }} - + {% include "common/header.j2.inc" %}
- + {% include "common/navigation.j2.inc" %}

{{ _("Operate a Taler exchange!") }}

@@ -77,7 +77,7 @@

- + {% include "common/footer.j2.inc" %}
diff --git a/locale/de/LC_MESSAGES/messages.po b/locale/de/LC_MESSAGES/messages.po index da39dca1..9c02b0f4 100644 --- a/locale/de/LC_MESSAGES/messages.po +++ b/locale/de/LC_MESSAGES/messages.po @@ -3,7 +3,7 @@ msgid "" msgstr "" "Project-Id-Version: PROJECT VERSION\n" "Report-Msgid-Bugs-To: EMAIL@ADDRESS\n" -"POT-Creation-Date: 2017-01-30 19:48+0100\n" +"POT-Creation-Date: 2017-01-30 21:27+0100\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language: de\n" @@ -14,17 +14,13 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Generated-By: Babel 2.3.4\n" -#: about.html.j2:2 about.html.j2:7 about.html.j2:11 about.html.j2:118 -#: citizens.html.j2:2 citizens.html.j2:7 citizens.html.j2:11 -#: citizens.html.j2:101 developers.html.j2:2 developers.html.j2:7 -#: developers.html.j2:11 developers.html.j2:216 financial-news.html.j2:7 -#: financial-news.html.j2:11 financial-news.html.j2:203 governments.html.j2:2 -#: governments.html.j2:7 governments.html.j2:11 governments.html.j2:101 -#: index.html.j2:2 investors.html.j2:2 investors.html.j2:7 investors.html.j2:11 -#: investors.html.j2:80 merchants.html.j2:2 merchants.html.j2:7 -#: merchants.html.j2:11 merchants.html.j2:137 news.html.j2:2 news.html.j2:7 -#: news.html.j2:11 news.html.j2:117 wallet.html.j2:2 wallet.html.j2:7 -#: wallet.html.j2:112 wallet.html.j2:194 +#: about.html.j2:2 about.html.j2:118 citizens.html.j2:2 developers.html.j2:2 +#: governments.html.j2:2 governments.html.j2:7 governments.html.j2:11 +#: governments.html.j2:101 investors.html.j2:2 investors.html.j2:7 +#: investors.html.j2:11 investors.html.j2:80 merchants.html.j2:2 +#: merchants.html.j2:7 merchants.html.j2:11 merchants.html.j2:137 +#: news.html.j2:2 wallet.html.j2:2 wallet.html.j2:7 wallet.html.j2:112 +#: wallet.html.j2:194 msgid "en" msgstr "de" @@ -1565,3 +1561,8 @@ msgstr "" #~ msgid "About us" #~ msgstr "Über uns" +#~ msgid "" +#~ "This page was created using Free Software only." +#~ msgstr "" + diff --git a/locale/en/LC_MESSAGES/messages.po b/locale/en/LC_MESSAGES/messages.po index 1837f597..4295c6b3 100644 --- a/locale/en/LC_MESSAGES/messages.po +++ b/locale/en/LC_MESSAGES/messages.po @@ -3,7 +3,7 @@ msgid "" msgstr "" "Project-Id-Version: PROJECT VERSION\n" "Report-Msgid-Bugs-To: EMAIL@ADDRESS\n" -"POT-Creation-Date: 2017-01-30 19:48+0100\n" +"POT-Creation-Date: 2017-01-30 21:27+0100\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language: en\n" @@ -14,17 +14,13 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Generated-By: Babel 2.3.4\n" -#: about.html.j2:2 about.html.j2:7 about.html.j2:11 about.html.j2:118 -#: citizens.html.j2:2 citizens.html.j2:7 citizens.html.j2:11 -#: citizens.html.j2:101 developers.html.j2:2 developers.html.j2:7 -#: developers.html.j2:11 developers.html.j2:216 financial-news.html.j2:7 -#: financial-news.html.j2:11 financial-news.html.j2:203 governments.html.j2:2 -#: governments.html.j2:7 governments.html.j2:11 governments.html.j2:101 -#: index.html.j2:2 investors.html.j2:2 investors.html.j2:7 investors.html.j2:11 -#: investors.html.j2:80 merchants.html.j2:2 merchants.html.j2:7 -#: merchants.html.j2:11 merchants.html.j2:137 news.html.j2:2 news.html.j2:7 -#: news.html.j2:11 news.html.j2:117 wallet.html.j2:2 wallet.html.j2:7 -#: wallet.html.j2:112 wallet.html.j2:194 +#: about.html.j2:2 about.html.j2:118 citizens.html.j2:2 developers.html.j2:2 +#: governments.html.j2:2 governments.html.j2:7 governments.html.j2:11 +#: governments.html.j2:101 investors.html.j2:2 investors.html.j2:7 +#: investors.html.j2:11 investors.html.j2:80 merchants.html.j2:2 +#: merchants.html.j2:7 merchants.html.j2:11 merchants.html.j2:137 +#: news.html.j2:2 wallet.html.j2:2 wallet.html.j2:7 wallet.html.j2:112 +#: wallet.html.j2:194 msgid "en" msgstr "" @@ -1052,3 +1048,8 @@ msgstr "" #~ msgid "About us" #~ msgstr "" +#~ msgid "" +#~ "This page was created using Free Software only." +#~ msgstr "" + diff --git a/locale/es/LC_MESSAGES/messages.po b/locale/es/LC_MESSAGES/messages.po index 84a36c3c..4bc2d89b 100644 --- a/locale/es/LC_MESSAGES/messages.po +++ b/locale/es/LC_MESSAGES/messages.po @@ -3,7 +3,7 @@ msgid "" msgstr "" "Project-Id-Version: PROJECT VERSION\n" "Report-Msgid-Bugs-To: EMAIL@ADDRESS\n" -"POT-Creation-Date: 2017-01-30 19:48+0100\n" +"POT-Creation-Date: 2017-01-30 21:27+0100\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language: es\n" @@ -14,17 +14,13 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Generated-By: Babel 2.3.4\n" -#: about.html.j2:2 about.html.j2:7 about.html.j2:11 about.html.j2:118 -#: citizens.html.j2:2 citizens.html.j2:7 citizens.html.j2:11 -#: citizens.html.j2:101 developers.html.j2:2 developers.html.j2:7 -#: developers.html.j2:11 developers.html.j2:216 financial-news.html.j2:7 -#: financial-news.html.j2:11 financial-news.html.j2:203 governments.html.j2:2 -#: governments.html.j2:7 governments.html.j2:11 governments.html.j2:101 -#: index.html.j2:2 investors.html.j2:2 investors.html.j2:7 investors.html.j2:11 -#: investors.html.j2:80 merchants.html.j2:2 merchants.html.j2:7 -#: merchants.html.j2:11 merchants.html.j2:137 news.html.j2:2 news.html.j2:7 -#: news.html.j2:11 news.html.j2:117 wallet.html.j2:2 wallet.html.j2:7 -#: wallet.html.j2:112 wallet.html.j2:194 +#: about.html.j2:2 about.html.j2:118 citizens.html.j2:2 developers.html.j2:2 +#: governments.html.j2:2 governments.html.j2:7 governments.html.j2:11 +#: governments.html.j2:101 investors.html.j2:2 investors.html.j2:7 +#: investors.html.j2:11 investors.html.j2:80 merchants.html.j2:2 +#: merchants.html.j2:7 merchants.html.j2:11 merchants.html.j2:137 +#: news.html.j2:2 wallet.html.j2:2 wallet.html.j2:7 wallet.html.j2:112 +#: wallet.html.j2:194 msgid "en" msgstr "es" @@ -1575,3 +1571,8 @@ msgstr "" #~ msgid "About us" #~ msgstr "Quiénes somos" +#~ msgid "" +#~ "This page was created using Free Software only." +#~ msgstr "" + diff --git a/locale/fr/LC_MESSAGES/messages.po b/locale/fr/LC_MESSAGES/messages.po index f5ef49d4..78bd85da 100644 --- a/locale/fr/LC_MESSAGES/messages.po +++ b/locale/fr/LC_MESSAGES/messages.po @@ -3,7 +3,7 @@ msgid "" msgstr "" "Project-Id-Version: PROJECT VERSION\n" "Report-Msgid-Bugs-To: EMAIL@ADDRESS\n" -"POT-Creation-Date: 2017-01-30 19:48+0100\n" +"POT-Creation-Date: 2017-01-30 21:27+0100\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language: fr\n" @@ -14,17 +14,13 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Generated-By: Babel 2.3.4\n" -#: about.html.j2:2 about.html.j2:7 about.html.j2:11 about.html.j2:118 -#: citizens.html.j2:2 citizens.html.j2:7 citizens.html.j2:11 -#: citizens.html.j2:101 developers.html.j2:2 developers.html.j2:7 -#: developers.html.j2:11 developers.html.j2:216 financial-news.html.j2:7 -#: financial-news.html.j2:11 financial-news.html.j2:203 governments.html.j2:2 -#: governments.html.j2:7 governments.html.j2:11 governments.html.j2:101 -#: index.html.j2:2 investors.html.j2:2 investors.html.j2:7 investors.html.j2:11 -#: investors.html.j2:80 merchants.html.j2:2 merchants.html.j2:7 -#: merchants.html.j2:11 merchants.html.j2:137 news.html.j2:2 news.html.j2:7 -#: news.html.j2:11 news.html.j2:117 wallet.html.j2:2 wallet.html.j2:7 -#: wallet.html.j2:112 wallet.html.j2:194 +#: about.html.j2:2 about.html.j2:118 citizens.html.j2:2 developers.html.j2:2 +#: governments.html.j2:2 governments.html.j2:7 governments.html.j2:11 +#: governments.html.j2:101 investors.html.j2:2 investors.html.j2:7 +#: investors.html.j2:11 investors.html.j2:80 merchants.html.j2:2 +#: merchants.html.j2:7 merchants.html.j2:11 merchants.html.j2:137 +#: news.html.j2:2 wallet.html.j2:2 wallet.html.j2:7 wallet.html.j2:112 +#: wallet.html.j2:194 msgid "en" msgstr "fr" @@ -1561,3 +1557,8 @@ msgstr "" #~ msgid "About us" #~ msgstr "À propos" +#~ msgid "" +#~ "This page was created using Free Software only." +#~ msgstr "" + diff --git a/locale/it/LC_MESSAGES/messages.po b/locale/it/LC_MESSAGES/messages.po index 88ee03e4..2df87084 100644 --- a/locale/it/LC_MESSAGES/messages.po +++ b/locale/it/LC_MESSAGES/messages.po @@ -3,7 +3,7 @@ msgid "" msgstr "" "Project-Id-Version: PROJECT VERSION\n" "Report-Msgid-Bugs-To: EMAIL@ADDRESS\n" -"POT-Creation-Date: 2017-01-30 19:48+0100\n" +"POT-Creation-Date: 2017-01-30 21:27+0100\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language: it\n" @@ -14,17 +14,13 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Generated-By: Babel 2.3.4\n" -#: about.html.j2:2 about.html.j2:7 about.html.j2:11 about.html.j2:118 -#: citizens.html.j2:2 citizens.html.j2:7 citizens.html.j2:11 -#: citizens.html.j2:101 developers.html.j2:2 developers.html.j2:7 -#: developers.html.j2:11 developers.html.j2:216 financial-news.html.j2:7 -#: financial-news.html.j2:11 financial-news.html.j2:203 governments.html.j2:2 -#: governments.html.j2:7 governments.html.j2:11 governments.html.j2:101 -#: index.html.j2:2 investors.html.j2:2 investors.html.j2:7 investors.html.j2:11 -#: investors.html.j2:80 merchants.html.j2:2 merchants.html.j2:7 -#: merchants.html.j2:11 merchants.html.j2:137 news.html.j2:2 news.html.j2:7 -#: news.html.j2:11 news.html.j2:117 wallet.html.j2:2 wallet.html.j2:7 -#: wallet.html.j2:112 wallet.html.j2:194 +#: about.html.j2:2 about.html.j2:118 citizens.html.j2:2 developers.html.j2:2 +#: governments.html.j2:2 governments.html.j2:7 governments.html.j2:11 +#: governments.html.j2:101 investors.html.j2:2 investors.html.j2:7 +#: investors.html.j2:11 investors.html.j2:80 merchants.html.j2:2 +#: merchants.html.j2:7 merchants.html.j2:11 merchants.html.j2:137 +#: news.html.j2:2 wallet.html.j2:2 wallet.html.j2:7 wallet.html.j2:112 +#: wallet.html.j2:194 msgid "en" msgstr "it" @@ -1573,3 +1569,8 @@ msgstr "" #~ msgid "About us" #~ msgstr "Chi siamo" +#~ msgid "" +#~ "This page was created using Free Software only." +#~ msgstr "" + diff --git a/merchants.html.j2 b/merchants.html.j2 index 3ad6fe0c..48ea6019 100644 --- a/merchants.html.j2 +++ b/merchants.html.j2 @@ -4,11 +4,11 @@ {{ _("GNU Taler") }} - {{ _("Merchants") }} - + {% include "common/header.j2.inc" %}
- + {% include "common/navigation.j2.inc" %}

{{ _("Advantages for merchants") }}

@@ -134,7 +134,7 @@

- + {% include "common/footer.j2.inc" %}
diff --git a/news.html.j2 b/news.html.j2 index 9c029d94..0063806c 100644 --- a/news.html.j2 +++ b/news.html.j2 @@ -4,11 +4,11 @@ {{ _("GNU Taler") }} - {{ _("News") }} - + {% include "common/header.j2.inc" %}
- + {% include "common/navigation.j2.inc" %}

{{ _("News") }}

@@ -114,7 +114,7 @@
- + {% include "common/footer.j2.inc" %} diff --git a/template.py b/template.py index aab6fddd..1fdf3b85 100755 --- a/template.py +++ b/template.py @@ -2,6 +2,7 @@ import os import sys +import re import gettext import jinja2 @@ -10,7 +11,8 @@ if len(sys.argv) < 3: in_file = sys.argv[1] locale = sys.argv[2] -out_file = sys.argv[3] + +name, ext = re.match(r"(.*)\.([^.]+)$", in_file.rstrip(".j2")).groups() tr = gettext.translation("messages", localedir="locale", @@ -23,12 +25,19 @@ env.install_gettext_translations(tr, newstyle=True) tmpl = env.get_template(in_file) +def self_localized(x): + return ".".join((name, x, ext)) + +def url_localized(my_file): + my_name, my_ext = re.match(r"(.*)\.([^.]+)$", my_file).groups() + return ".".join((my_name, locale, my_ext)) + def url(x): # TODO: look at the app root environment variable # TODO: check if file exists return x import codecs -f = codecs.open(out_file, "w", "utf-8") -f.write(tmpl.render(lang=locale, url=url)) +f = codecs.open(".".join((name, locale, ext)), "w", "utf-8") +f.write(tmpl.render(lang=locale, url=url, self_localized=self_localized, url_localized=url_localized)) f.close() diff --git a/template.sh b/template.sh index bc63b943..a33cefe8 100755 --- a/template.sh +++ b/template.sh @@ -4,6 +4,6 @@ for f in $(git ls-files *.j2); do for ld in locale/*/; do l=$(basename $ld) echo "$f: $l" - python template.py $f $l $(dirname $f)/$(basename $f .html.j2).$l.html + python template.py $f $l done done diff --git a/wallet.html.j2 b/wallet.html.j2 index b828091a..0e45b2c4 100644 --- a/wallet.html.j2 +++ b/wallet.html.j2 @@ -4,7 +4,7 @@ {{ _("GNU Taler") }} - {{ _("Wallet") }} - + {% include "common/header.j2.inc" %} @@ -109,7 +109,7 @@ document.addEventListener('DOMContentLoaded', onLoad);
- + {% include "common/navigation.j2.inc" %}

Taler Wallet

@@ -191,7 +191,7 @@ document.addEventListener('DOMContentLoaded', onLoad);
- + {% include "common/footer.j2.inc" %}
-- cgit v1.2.3