diff options
| author | thomasb <thomasb@208e9e7b-5314-0410-a742-e7e81cd9613c> | 2011-12-07 08:51:01 +0000 |
|---|---|---|
| committer | thomasb <thomasb@208e9e7b-5314-0410-a742-e7e81cd9613c> | 2011-12-07 08:51:01 +0000 |
| commit | 6ed8cc03973eb29bc59416689758d37d3e9af2a4 (patch) | |
| tree | a8780cba13968791582cb693fb82eab4d0c8d042 /roundcubemail/bin/exportgettext.sh | |
| parent | 4966fc7f22a28e2eb0de256bb44613f0e580a111 (diff) | |
Fix newline handling in gettext export; add import script to read .po localization files
git-svn-id: https://svn.roundcube.net/trunk@5558 208e9e7b-5314-0410-a742-e7e81cd9613c
Diffstat (limited to 'roundcubemail/bin/exportgettext.sh')
| -rwxr-xr-x | roundcubemail/bin/exportgettext.sh | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/roundcubemail/bin/exportgettext.sh b/roundcubemail/bin/exportgettext.sh index f59474ec0..9a935dab4 100755 --- a/roundcubemail/bin/exportgettext.sh +++ b/roundcubemail/bin/exportgettext.sh @@ -7,7 +7,7 @@ | | | This file is part of the Roundcube Webmail client | | Copyright (C) 2011, The Roundcube Dev Team | - | Licensed under the GNU GPLv3 | + | Licensed under the GNU General Public License | | | | PURPOSE: | | Export PHP-based localization files to PO files for gettext | @@ -187,10 +187,9 @@ EOF; function gettext_quote($str) { $out = ""; - $lines = explode("\n", stripslashes($str)); - $suffix = count($lines) > 1 ? '\n' : ''; + $lines = explode("\n", wordwrap(stripslashes($str))); foreach ($lines as $line) - $out .= '"' . addcslashes($line, '"') . $suffix . "\"\n"; + $out .= '"' . addcslashes($line, '"') . "\"\n"; return rtrim($out); } |
