TOML

在 5.15 版被加入.

備註

Support for this format is under development. Some features might not yet be available and the behavior can change between releases. Feedback from testing is welcome.

TOML is a generic format like YAML 檔案 or JSON 檔案 and can be used to localize applications.

Weblate supports TOML in several variants:

TOML 檔案

Plain TOML file without support for plurals.

go-i18n TOML 檔案

go-i18n variant with plurals support.

範例檔案:

hello = "Ahoj světe!\n"
orangutan = "Orangutan má %d banán.\n"
thanks = "Děkujeme za použití Weblate."
try = "Zkus Weblate na <https://demo.weblate.org/>!\n"
[hello]
other = "Ahoj světe!\n"

[orangutan]
one = "Orangutan má %d banán.\n"
other = "Orangutan má %d banány.\n"

[thanks]
other = "Děkujeme za použití Weblate."

[try]
other = "Zkus Weblate na <https://demo.weblate.org/>!\n"
支援的功能

副檔名

.toml

語言能力

單語言

支援複數

No

支援描述

No

支援解釋

No

Supports context

No

Supports location

No

Supports flags

No

API 識別碼

toml

支援唯讀字串

No

Weblate 配置

典型的 Weblate 組件配置

檔案遮罩

langs/*.toml

單語的基底語言檔案

langs/en.toml

新翻譯的範本

空白

檔案格式

TOML 檔案