parent
e2f2f4f779
commit
3bedb42b0b
|
@ -18,7 +18,8 @@ Here are the current `config.toml` sections:
|
|||
4. slugify
|
||||
5. search
|
||||
6. translations
|
||||
7. extra
|
||||
7. languages
|
||||
8. extra
|
||||
|
||||
**Only the `base_url` variable is mandatory**. Everything else is optional. All configuration variables
|
||||
used by Zola as well as their default values are listed below:
|
||||
|
@ -72,27 +73,17 @@ feed_filename = "atom.xml"
|
|||
# files are always copied, regardless of this setting.
|
||||
hard_link_static = false
|
||||
|
||||
# The taxonomies to be rendered for the site and their configuration.
|
||||
# The taxonomies to be rendered for the site and their configuration of the default languages
|
||||
# Example:
|
||||
# taxonomies = [
|
||||
# {name = "tags", feed = true}, # each tag will have its own feed
|
||||
# {name = "tags", lang = "fr"}, # you can have taxonomies with the same name in multiple languages
|
||||
# {name = "tags"}, # you can have taxonomies with the same name in multiple languages
|
||||
# {name = "categories", paginate_by = 5}, # 5 items per page for a term
|
||||
# {name = "authors"}, # Basic definition: no feed or pagination
|
||||
# ]
|
||||
#
|
||||
taxonomies = []
|
||||
|
||||
# The additional languages for the site.
|
||||
# Example:
|
||||
# languages = [
|
||||
# {code = "fr", feed = true}, # there will be a feed for French content
|
||||
# {code = "fr", search = true}, # there will be a Search Index for French content
|
||||
# {code = "it"}, # there won't be a feed for Italian content
|
||||
# ]
|
||||
#
|
||||
languages = []
|
||||
|
||||
# A list of directories used to search for additional `.sublime-syntax` files.
|
||||
extra_syntaxes = []
|
||||
|
||||
|
@ -159,20 +150,30 @@ include_content = true
|
|||
# become too big to load on the site. Defaults to not being set.
|
||||
# truncate_content_length = 100
|
||||
|
||||
# Optional translation object. Keys should be language codes.
|
||||
# Optional translation object. The key if present should be a language code.
|
||||
# Optional translation object for the default language
|
||||
# Example:
|
||||
# default_language = "fr"
|
||||
#
|
||||
# [translations]
|
||||
# [translations.fr]
|
||||
# title = "Un titre"
|
||||
#
|
||||
# [translations.en]
|
||||
# title = "A title"
|
||||
#
|
||||
[translations]
|
||||
|
||||
# Additional languages definition
|
||||
# You can define language specific config values and translations:
|
||||
# title, description, generate_feed, feed_filename, taxonomies, build_search_index
|
||||
# as well as its own search configuration and translations (see above for details on those)
|
||||
[languages]
|
||||
# For example
|
||||
# [languages.fr]
|
||||
# title = "Mon blog"
|
||||
# generate_feed = true
|
||||
# taxonomies = [
|
||||
# {name = "auteurs"},
|
||||
# {name = "tags"},
|
||||
# ]
|
||||
# build_search_index = false
|
||||
|
||||
# You can put any kind of data here. The data
|
||||
# will be accessible in all templates
|
||||
# Example:
|
||||
|
|
|
@ -15,7 +15,7 @@ you can place `{{ __tera_context }}` in the template to print the whole context.
|
|||
|
||||
A few variables are available on all templates except feeds and the sitemap:
|
||||
|
||||
- `config`: the [configuration](@/documentation/getting-started/configuration.md) without any modifications
|
||||
- `config`: the language aware [configuration](@/documentation/getting-started/configuration.md)
|
||||
- `current_path`: the path (full URL without `base_url`) of the current page, always starting with a `/`
|
||||
- `current_url`: the full URL for the current page
|
||||
- `lang`: the language for the current page
|
||||
|
|
|
@ -19,8 +19,8 @@ taxonomies = [
|
|||
[languages.fr]
|
||||
generate_feed = true
|
||||
taxonomies = [
|
||||
{name = "auteurs", lang = "fr"},
|
||||
{name = "tags", lang = "fr"},
|
||||
{name = "auteurs"},
|
||||
{name = "tags"},
|
||||
]
|
||||
|
||||
[languages.it]
|
||||
|
|
Loading…
Reference in a new issue