Merge pull request #285 from cassiobatista/local-build-doc

Instructions for Multilingual added on README
This commit is contained in:
Michael Romero 2019-09-21 00:33:35 -07:00 committed by GitHub
commit 429e0af5e3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 27 additions and 0 deletions

View File

@ -121,6 +121,33 @@ enableGitInfo = true
```
See at [vincenttam/vincenttam.gitlab.io](https://gitlab.com/vincenttam/vincenttam.gitlab.io) for an example of how to add it to a continuous integration system.
### Multilingual
To allow Beautiful Hugo to go multilingual, you need to define the languages
you want to use inside the `languages` parameter on `config.toml` file, also
redefining the content dir for each one. Check the `i18n/` folder to see all
languages available.
```toml
[languages]
[languages.en]
contentDir = "content/en" # English
[languages.ja]
contentDir = "content/ja" # Japanese
[languages.br]
contentDir = "content/br" # Brazilian Portuguese
```
Now you just need to create a subdir within the `content/` folder for each
language and just put stuff inside `page/` and `post/` regular directories.
```
content/ content/ content/
└── en/ └── br/ └── ja/
   ├── page/ ├── page/    ├── page/
   └── post/ └── post/    └── post/
```
### Extra shortcodes