mirego / accent

The first developer-oriented translation tool. True asynchronous flow between translators and your team.
https://www.accent.reviews
BSD 3-Clause "New" or "Revised" License
1.25k stars 96 forks source link

Increase tolerance for Yaml files or increase tolerance for Yaml types #425

Open BingYanchi opened 5 months ago

BingYanchi commented 5 months ago

In Spigot, the default supported Yaml format is not the common Yaml format.

Them does not meet any of the four requirements for Yaml format.

Many programs use non-standard yaml formats, which makes it impossible to use Accent to localize them.

Example:

gui-area-title: "%queueDisplayName%"
#%serverName% - Raw server name
#%serverDisplayName% - Display name of the server
#%serverMotd% - MOTD of the server
#%serverPlayerNum% - Now players number of the server
#%serverMaxPlayerNum% - Max players number of the server
gui-area-match-server-name: "&a%serverDisplayName%"
gui-area-match-server-description: |-
  &8%queueDisplayName%

  &7Current player: &a%serverPlayerNum%&7 / &a%serverMaxPlayerNum%
  &7Current status: &a%serverMotd%

  &eClick to play
simonprev commented 4 months ago

Do you know what kind of "flavor" this YAML happens to be? The YAML support right now is pretty rudimentary (always wrapped in double quotes, no references, etc) and the libyaml is not working on arm64 architecture so I’m open on changing the library