pkp / translator

PKP Translator plugin for OMP 1.1.1+ and OJS 3.0+
GNU General Public License v2.0
6 stars 30 forks source link

Wrong file doctype, path information, and copyright date in files created by plugin #20

Open mtub opened 7 years ago

mtub commented 7 years ago

When the translator plugin creates new files, some of the XML file header lines differ from the en_US original file (at least with plugin translations):

This results in us getting translations that need unnecessary cleanup, because at least the dtd error has to be removed.

To verify:

Example

en_US

<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE locale SYSTEM "../../../../../lib/pkp/dtd/locale.dtd"> ` <!-- plugins/generic/googleScholar/locale/en_US/locale.xml Copyright (c) 2014-2017 Simon Fraser University Copyright (c) 2003-2017 John Willinsky`

newly created de_DE file

<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE locale SYSTEM "../../../../lib/pkp/dtd/locale.dtd"> ` <!-- locale/de_DE/locale.xml Copyright (c) 2014-2016 Simon Fraser University Library Copyright (c) 2003-2016 John Willinsky`

asmecher commented 7 years ago

The blank comes from registry/locale.xml in the plugin repo, just FYI. More of the header stuff could stand to be made into variables rather than taken directly from the blank.

zuphilip commented 6 years ago

See also https://github.com/ajnyga/disqus/pull/4 for an example of such cleanup, which would make more sense to do it correctly in the translator plugin in the first place.

mtub commented 6 years ago

Since this results in many extra hours of work to track the errors introduced by the plugin, I would really welcome a fix for this, @asmecher.