Fix locale on different systems

This commit is contained in:
Alexis Métaireau 2023-12-16 23:57:44 +01:00
parent c9c9026ebf
commit 2d3c392435

View file

@ -9,7 +9,10 @@ from pelican import signals
from pelican.readers import Markdown, MarkdownReader, pelican_open from pelican.readers import Markdown, MarkdownReader, pelican_open
from pelican.utils import get_date, slugify from pelican.utils import get_date, slugify
try:
locale.setlocale(locale.LC_TIME, "fr_FR.UTF8") locale.setlocale(locale.LC_TIME, "fr_FR.UTF8")
except:
locale.setlocale(locale.LC_TIME, "fr_FR")
class WorklogPreprocessor(Preprocessor): class WorklogPreprocessor(Preprocessor):