Hello i18n.
This commit is contained in:
parent
cad60f2f32
commit
caf3ee3017
|
@ -2,3 +2,6 @@
|
||||||
.venv/
|
.venv/
|
||||||
output/
|
output/
|
||||||
__pycache__/
|
__pycache__/
|
||||||
|
Flex/
|
||||||
|
pelican-plugins/
|
||||||
|
.envrc
|
||||||
|
|
12
Makefile
12
Makefile
|
@ -45,13 +45,16 @@ help:
|
||||||
Flex/.git/config:
|
Flex/.git/config:
|
||||||
git clone --depth 1 https://github.com/alexandrevicenzi/Flex
|
git clone --depth 1 https://github.com/alexandrevicenzi/Flex
|
||||||
|
|
||||||
html: Flex/.git/config
|
pelican-plugins/.git/config:
|
||||||
|
git clone --depth 1 https://github.com/getpelican/pelican-plugins
|
||||||
|
|
||||||
|
html: Flex/.git/config pelican-plugins/.git/config
|
||||||
$(PELICAN) $(INPUTDIR) -o $(OUTPUTDIR) -s $(CONFFILE) $(PELICANOPTS)
|
$(PELICAN) $(INPUTDIR) -o $(OUTPUTDIR) -s $(CONFFILE) $(PELICANOPTS)
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
[ ! -d $(OUTPUTDIR) ] || rm -rf $(OUTPUTDIR)
|
[ ! -d $(OUTPUTDIR) ] || rm -rf $(OUTPUTDIR)
|
||||||
|
|
||||||
regenerate: Flex/.git/config
|
regenerate: Flex/.git/config pelican-plugins/.git/config
|
||||||
$(PELICAN) -r $(INPUTDIR) -o $(OUTPUTDIR) -s $(CONFFILE) $(PELICANOPTS)
|
$(PELICAN) -r $(INPUTDIR) -o $(OUTPUTDIR) -s $(CONFFILE) $(PELICANOPTS)
|
||||||
|
|
||||||
serve:
|
serve:
|
||||||
|
@ -76,12 +79,9 @@ else
|
||||||
$(PELICAN) -lr $(INPUTDIR) -o $(OUTPUTDIR) -s $(CONFFILE) $(PELICANOPTS)
|
$(PELICAN) -lr $(INPUTDIR) -o $(OUTPUTDIR) -s $(CONFFILE) $(PELICANOPTS)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
publish: Flex/.git/config
|
publish: Flex/.git/config pelican-plugins/.git/config
|
||||||
$(PELICAN) $(INPUTDIR) -o $(OUTPUTDIR) -s $(PUBLISHCONF) $(PELICANOPTS)
|
$(PELICAN) $(INPUTDIR) -o $(OUTPUTDIR) -s $(PUBLISHCONF) $(PELICANOPTS)
|
||||||
|
|
||||||
ssh_upload: publish
|
|
||||||
scp -P $(SSH_PORT) -r $(OUTPUTDIR)/* $(SSH_USER)@$(SSH_HOST):$(SSH_TARGET_DIR)
|
|
||||||
|
|
||||||
rsync_upload: publish
|
rsync_upload: publish
|
||||||
rsync -e "ssh -p $(SSH_PORT)" -P -rvzc --cvs-exclude $(OUTPUTDIR)/ $(SSH_USER)@$(SSH_HOST):$(SSH_TARGET_DIR)
|
rsync -e "ssh -p $(SSH_PORT)" -P -rvzc --cvs-exclude $(OUTPUTDIR)/ $(SSH_USER)@$(SSH_HOST):$(SSH_TARGET_DIR)
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,23 @@
|
||||||
|
Title: Julien Palard
|
||||||
|
Date: 2016-05-28
|
||||||
|
description: Julien Palard - mdk.fr
|
||||||
|
status: hidden
|
||||||
|
lang: en
|
||||||
|
URL:
|
||||||
|
save_as: index.html
|
||||||
|
|
||||||
|
CPython core developer, PSF fellow, independent Python trainer.
|
||||||
|
|
||||||
|
My projects:
|
||||||
|
|
||||||
|
- I build an interactive Python learning tool: [hackinscience.org](https://hackinscience.org/), it's free and [open-source](https://framagit.org/hackinscience/).
|
||||||
|
- I help translating the [Python documentation in French](https://docs.python.org/fr/) (come and help [here](https://github.com/python/python-docs-fr)).
|
||||||
|
- Other projects on [AFPy's gitea](https://git.afpy.org/mdk) and [my github](https://github.com/JulienPalard).
|
||||||
|
|
||||||
|
If you want to get in touch:
|
||||||
|
|
||||||
|
- By email: <a href=mailto:julien@palard.fr>julien@palard.fr</a>.
|
||||||
|
- On [Mastodon](https://joinmastodon.org): [@mdk@mamot.fr](https://mamot.fr/@mdk)
|
||||||
|
- On [IRC](https://web.libera.chat/#python-fr): `mdk`.
|
||||||
|
- Using [XMPP](https://xmpp.chapril.org/i/mdk@chapril.org): <a href=xmpp:mdk@chapril.org>mdk@chapril.org</a>.
|
||||||
|
- Here is My [GPG key](/Julien-Palard.pdf) and my [SSH keys](/id_rsa.pub).
|
|
@ -2,20 +2,22 @@ Title: Julien Palard
|
||||||
Date: 2016-05-28
|
Date: 2016-05-28
|
||||||
description: Julien Palard - mdk.fr
|
description: Julien Palard - mdk.fr
|
||||||
status: hidden
|
status: hidden
|
||||||
|
lang: fr
|
||||||
URL:
|
URL:
|
||||||
save_as: index.html
|
save_as: index.html
|
||||||
|
|
||||||
CPython core developer, PSF fellow, independent Python trainer.
|
Formateur Python indépendant, CPython core developer, PSF fellow.
|
||||||
|
|
||||||
My projects:
|
Mes projets:
|
||||||
|
|
||||||
- I build an interactive Python learning tool: [hackinscience.org](https://hackinscience.org/), it's free and [open-source](https://framagit.org/hackinscience/hkis-website).
|
- Je travaille sur un site d’apprentissage de la programmation interactif : [hackinscience.org](https://hackinscience.org/).
|
||||||
- I help translating the [Python documentation in French](https://docs.python.org/fr/) (come and help [here](https://github.com/python/python-docs-fr)).
|
- J'aide à la traduction de la [documentation de Python en Français](https://docs.python.org/fr/) (pour participer c'est [ici](https://git.afpy.org/AFPy/python-docs-fr)).
|
||||||
- Other projects on [AFPy's gitea](https://git.afpy.org/mdk) and [my github](https://github.com/JulienPalard).
|
- Mes autres projets sont sur la [forge de l'AFPy](https://git.afpy.org/mdk) et sur [mon github](https://github.com/JulienPalard).
|
||||||
|
|
||||||
If you want to get in touch:
|
Pour me contacter :
|
||||||
|
|
||||||
- I'm [@mdk@mamot.fr](https://mamot.fr/@mdk) on [Mastodon](https://joinmastodon.org).
|
- Par email : <a href=mailto:julien@palard.fr>julien@palard.fr</a>.
|
||||||
- I'm `mdk` on [IRC](https://web.libera.chat/#python-fr)
|
- Sur [Mastodon](https://joinmastodon.org) : [@mdk@mamot.fr](https://mamot.fr/@mdk).
|
||||||
- I'm <a href=xmpp:mdk@chapril.org>mdk@chapril.org</a> on [XMPP](https://xmpp.chapril.org/i/mdk@chapril.org).
|
- Sur [irc://libera.chat](https://web.libera.chat/#python-fr) : `mdk`.
|
||||||
- I'm <a href=mailto:julien@palard.fr>julien@palard.fr</a> by email.
|
- Sur [XMPP](https://xmpp.chapril.org/i/mdk@chapril.org) <a href=xmpp:mdk@chapril.org>mdk@chapril.org</a>.
|
||||||
|
- Voilà ma [clé GPG](/Julien-Palard.pdf) et ma [clé SSH](/id_rsa.pub).
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
from datetime import date
|
from datetime import date
|
||||||
|
|
||||||
|
|
||||||
AUTHOR = "Julien Palard"
|
AUTHOR = "Julien Palard"
|
||||||
SITENAME = "mdk.fr"
|
SITENAME = "mdk.fr"
|
||||||
SITETITLE = "Julien Palard"
|
SITETITLE = "Julien Palard"
|
||||||
|
@ -15,17 +16,48 @@ DISABLE_URL_HASH = True
|
||||||
FAVICON = "/images/favicon.png"
|
FAVICON = "/images/favicon.png"
|
||||||
|
|
||||||
DISPLAY_PAGES_ON_MENU = False
|
DISPLAY_PAGES_ON_MENU = False
|
||||||
MAIN_MENU = False
|
MAIN_MENU = True
|
||||||
|
|
||||||
LINKS = (
|
MENUITEMS = (
|
||||||
("Formations", "/pages/formations.html"),
|
("Formations", "/pages/formations.html"),
|
||||||
("Conférences", "/pages/talks.html"),
|
("Conférences", "/pages/talks.html"),
|
||||||
("CV", "/Julien-Palard.pdf"),
|
("Articles", "/blog/"),
|
||||||
("Blog", "/blog/"),
|
|
||||||
("SSH keys", "/id_rsa.pub"),
|
|
||||||
("GPG key", "/pages/gpg.html"),
|
|
||||||
)
|
)
|
||||||
|
|
||||||
|
LINKS = (
|
||||||
|
)
|
||||||
|
|
||||||
|
# Social widget
|
||||||
|
SOCIAL = (
|
||||||
|
("mastodon", "https://mamot.fr/@mdk"),
|
||||||
|
("github", "https://github.com/julienpalard"),
|
||||||
|
("stack-overflow", "https://stackoverflow.com/users/232831/julien-palard"),
|
||||||
|
("rss", "/feeds/all.atom.xml"),
|
||||||
|
)
|
||||||
|
|
||||||
|
# Path to Plugins
|
||||||
|
PLUGIN_PATHS = ['pelican-plugins']
|
||||||
|
# Enable i18n plugin, probably you already have some others here.
|
||||||
|
PLUGINS = ['i18n_subsites']
|
||||||
|
# Enable Jinja2 i18n extension used to parse translations.
|
||||||
|
JINJA_ENVIRONMENT = {'extensions': ['jinja2.ext.i18n']}
|
||||||
|
I18N_TEMPLATES_LANG = "en"
|
||||||
|
|
||||||
|
# Match languages for other configs.
|
||||||
|
OG_LOCALE = "fr_FR"
|
||||||
|
LOCALE = ("fr_FR", "fr_FR.utf8")
|
||||||
|
|
||||||
|
# Your language.
|
||||||
|
DEFAULT_LANG = "fr_FR"
|
||||||
|
|
||||||
|
I18N_SUBSITES = {
|
||||||
|
'en': {
|
||||||
|
'SITENAME': 'English Julien Palard',
|
||||||
|
'LOCALE': 'en_US',
|
||||||
|
'THEME_STATIC_DIR': '../theme'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
PATH = "content"
|
PATH = "content"
|
||||||
|
|
||||||
TIMEZONE = "Europe/Paris"
|
TIMEZONE = "Europe/Paris"
|
||||||
|
@ -39,27 +71,20 @@ TRANSLATION_FEED_ATOM = None
|
||||||
AUTHOR_FEED_ATOM = None
|
AUTHOR_FEED_ATOM = None
|
||||||
AUTHOR_FEED_RSS = None
|
AUTHOR_FEED_RSS = None
|
||||||
|
|
||||||
THEME_COLOR = "dark"
|
THEME_COLOR = "light"
|
||||||
THEME_COLOR_AUTO_DETECT_BROWSER_PREFERENCE = True
|
THEME_COLOR_AUTO_DETECT_BROWSER_PREFERENCE = True
|
||||||
THEME_COLOR_ENABLE_USER_OVERRIDE = True
|
THEME_COLOR_ENABLE_USER_OVERRIDE = False
|
||||||
|
|
||||||
PYGMENTS_STYLE = "emacs"
|
PYGMENTS_STYLE = "emacs"
|
||||||
PYGMENTS_STYLE_DARK = "monokai"
|
PYGMENTS_STYLE_DARK = "monokai"
|
||||||
|
|
||||||
# Social widget
|
|
||||||
SOCIAL = (
|
|
||||||
("mastodon", "https://mamot.fr/@mdk"),
|
|
||||||
("github", "https://github.com/julienpalard"),
|
|
||||||
("stack-overflow", "https://stackoverflow.com/users/232831/julien-palard"),
|
|
||||||
("rss", "/feeds/all.atom.xml"),
|
|
||||||
)
|
|
||||||
|
|
||||||
USE_GOOGLE_FONTS = False
|
USE_GOOGLE_FONTS = False
|
||||||
DEFAULT_PAGINATION = 10
|
DEFAULT_PAGINATION = 10
|
||||||
THEME = "Flex"
|
THEME = "Flex"
|
||||||
THEME_STATIC_DIR = "theme"
|
THEME_STATIC_DIR = "theme"
|
||||||
ARTICLE_URL = "{category}/{slug}.html"
|
ARTICLE_URL = "{category}/{slug}.html"
|
||||||
STATIC_PATHS = ["images"]
|
STATIC_PATHS = ["images"]
|
||||||
|
|
||||||
ARTICLE_SAVE_AS = "{category}/{slug}.html"
|
ARTICLE_SAVE_AS = "{category}/{slug}.html"
|
||||||
CATEGORY_URL = "{slug}/"
|
CATEGORY_URL = "{slug}/"
|
||||||
CATEGORY_SAVE_AS = "{slug}/index.html"
|
CATEGORY_SAVE_AS = "{slug}/index.html"
|
||||||
|
|
Loading…
Reference in New Issue