mquinson / po4a

Maintain the translations of your documentation with ease (PO for anything)
http://po4a.org/
GNU General Public License v2.0
123 stars 61 forks source link

Asciidoctor/Front Matter YAML issue with tags #354

Closed dbaio closed 2 years ago

dbaio commented 2 years ago

Source file. PO file.

PO pt-br. Output file in pt-br.

po4a version 0.66 and prior releases has the same issue.

po4a-gettextize \
        --format asciidoc \
        --option compat=asciidoctor \
        --option yfm_keys=title,part,description \
        --master "po4a-asciidoctor-fm.adoc" \
        --master-charset "UTF-8" \
        --copyright-holder "The FreeBSD Project" \
        --package-name "FreeBSD Documentation" \
        --po "po4a-asciidoctor-fm.po"
po4a-translate \
                --format asciidoc \
                --option compat=asciidoctor \
                --option yfm_keys=title,part,description \
                --master "po4a-asciidoctor-fm.adoc" \
                --master-charset "UTF-8" \
                --po "po4a-asciidoctor-fm_pt-br.po" \
                --localized "po4a-asciidoctor-fm_pt-br.adoc" \
                --localized-charset "UTF-8"

-->

Difference from the original and translated file:

-trademarks: ["freebsd", "intel", "general"]
+trademarks: '["freebsd", "intel", "general"]'

-tags: ["bsdl", "gpl", "FreeBSD License"]
+tags: '["bsdl", "gpl", "FreeBSD License"]'

It's inserting quotes when there are tags in the front matter.

I'm reporting this so others can help, but the plan is to dig/debug po4a later.

dbaio commented 2 years ago

Duplicated with #304