Skip to content

v2.2.0

Compare
Choose a tag to compare
@huacnlee huacnlee released this 28 Aug 07:09
· 81 commits to main since this release

What's Changed

  • Add to support translated text with multiple locales in one file. by @huacnlee in #50
  • Add _version for locale file for special the file format.
    • _version: 1 - Split each language into difference files (default).
    • _version: 2 - All language in same file.
  • Update cargo i18n command for output _version: 2 format.

Example

Write a app.yml

_version: 2
hello:
  en: "Hello"
  zh-CN: "你好"
  world:
    en: "Hello World"
    zh-CN: "你好世界"
welcome.message:
  en: "Welcome"
  zh-CN: "欢迎"

Screenshot

rust-i18n-example

Other Changes

  • Do not use . in macro output if locale string is empty. by @ajantti in #51
  • Some more fixes and improvements. by @ajantti in #53
  • Add a test for checking if tests are run single-threadedly. by @ajantti in #54
  • Improve generator output to remove leading --- in YAML file.

New Contributors

Full Changelog: v2.1.0...v2.2.0