[
https://issues.apache.org/jira/browse/ISIS-1070?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Dan Haywood updated ISIS-1070:
------------------------------
Fix Version/s: (was: 1.12.0)
1.11.0
> Add header and handle double quotes in translations.pot file
> -------------------------------------------------------------
>
> Key: ISIS-1070
> URL: https://issues.apache.org/jira/browse/ISIS-1070
> Project: Isis
> Issue Type: Improvement
> Components: Core
> Affects Versions: core-1.8.0
> Reporter: Jeroen van der Wal
> Assignee: Dan Haywood
> Priority: Minor
> Fix For: 1.11.0
>
>
> Some translation services are more picky about the format of the .pot file
> than others. I encountered two issues when trying a different service:
> 1. Add compliant header
> More about headers in this paper [1] and the gettext documentation [2]. I've
> successfully managed to upload a .pot file to a translation service by adding
> this header:
> {code}
> msgid ""
> msgstr ""
> "Project-Id-Version: \n"
> "POT-Creation-Date: 2015-03-04 12:52+0100\n"
> "MIME-Version: 1.0\n"
> "Content-Type: text/plain; charset=UTF-8\n"
> "Content-Transfer-Encoding: 8bit\n"
> "Plural-Forms: nplurals=2; plural=n != 1;\n"
> {code}
> 2. Escape quotes
> Some services can't deal with quotes in the translatable string:
> {code}
> msgid "<a href="#">Accept using your data for research</a>"
> {code}
> One could argue that is this particular example the html should not be
> exposed to the translator but it's imaginable that quotes are used in strings
> that are presented to the user.
> Escaping with a backslash allowed me to upload the .pot file:
> {code}
> msgid "<a href=\"#\">Accept using your data for research</a>"
> {code}
>
> [1] http://pology.nedohodnik.net/doc/user/en_US/ch-poformat.html
> [2]
> https://www.gnu.org/software/gettext/manual/html_node/Header-Entry.html#Header-Entry
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)