12 Commits

Author SHA1 Message Date
Mandaris
8799873565 Give information on how to set up in pelican
The plugin calls for the extension for the command “gettext” and
doesn’t write the text without it.
2017-11-15 06:03:43 -08:00
Deniz Turgut
cc0dd7f2d3 Update plugins that use JINJA_ENTENSIONS to the Pelican 3.7 setting JINJA_ENVIRONMENT
Plugins that were affected:
- assets
- i18n_subsites
- jinja2content
2016-12-15 04:18:20 -05:00
Ondrej Grover
806ae893e7 record hidden content in native lang, fixes #409
added 404 test pages for this case
2015-02-15 08:12:12 +01:00
Ondrej Grover
1e0684aa22 i18n_subsites: update test suite for Pelican 3.5.0
just add the timezone in dates
2015-02-15 07:55:43 +01:00
Ondrej Grover
4a6290378a Update the i18n_subsites plugin, addresses many issues
Major highlights
................
- fixed and improved cross-linking (fixes #333) with URLs
  containing e.g. localized month names
  (thanks to issue getpelican/pelican#1198)
- support for custom ``SITEURL`` and ``OUTPUT_PATH`` hierarchy
  (fixes #182)
- sharing of static files (including those of the theme) among
  subsites (fixes #180)

Technical highlights
....................
- added a test suite (works with pelican 3.4)
- translations are installed into Jinja2 environments of all
  generators
- old locale is restored after generation, fixes autoreload

The documentation has been updated and improved (mostly in terms of
formatting).

Known issues
............
- due to the redesign required for correct cross-linking, older
  versions of Pelican (<3.4) are not supported, because they lack
  certain signals
- the ``HIDE_UNTRANSLATED_CONTENT`` setting has been deprecated in
  favor of the ``I18N_UNTRANSLATED_{ARTICLES,PAGES}`` settings which
  offer more control in order to fix #211.
- the test suite works only with pelican 3.4, later versions add a
  timezone field to the date
2014-11-02 11:21:48 +01:00
Ondrej Grover
4c33944bb9 i18n_subsites: add lang_subsites template var, improve docs
- the new variable makes it easier to implement language buttons
- a short howto on language buttons is also provided
- the dictionary mapping template vars are now OrderedDict
  for consistent-looking language buttons
2014-02-05 21:42:12 +01:00
Ondrej Grover
aa5c414d0b 18n_subsites: use configure_settings() to sanitize
Also needed for LOCALE overrides, etc.
2014-02-04 15:07:24 +01:00
Ondrej Grover
8ee994b70d i18n_subsites: improve develop server support
1. main site url root fix
2. support autoreload mode
Also removed trailing slash on dir name.
2014-02-04 14:24:44 +01:00
Ondrej Grover
72b5de1af6 i18n_subsites: fix HIDE_UNTRANSLATED_CONTENT
1. was removing items of an active iterator -> only first worked
2. Article inherits Page, so first check if is Article
2014-02-04 14:14:43 +01:00
Ondrej Grover
0c172ba023 i18n_subsites: consider templates lang, expand docs
this commit removes the need to make a dummy translation for
the language in which the templates are written.
This only affects themes using jinja2.ext.i18n.
The I18N_THEMES_LANG is introduced to address this issue.

Also expanded the docs for making gettext .po files with babel.
2014-02-03 20:04:40 +01:00
Ondrej Grover
0ed8750b7d i18n_subsites plugin: implement jinja2.ext.i18n support
this commit introduces optional support for translatable templates
2014-02-02 16:50:15 -08:00
Ondrej Grover
e4fef3ebdf new plugin: i18n_subsites
This plugin extends the translations functionality by creating i8n-ized
sub-sites for the default site.
This commit implements the basic generation functionality.
2014-02-02 09:09:20 +01:00