From: Moritz Bunkus Date: Tue, 28 Dec 2010 13:18:43 +0000 (+0100) Subject: Perl-Scripte mit UTF-8 encodierten Umlaugen brauchen "use utf8" X-Git-Tag: release-2.6.2beta1~55^2~6 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=203ebd4a71a8de7d549db868b657232da36b6e82;p=kivitendo-erp.git Perl-Scripte mit UTF-8 encodierten Umlaugen brauchen "use utf8" --- diff --git a/locale/de/all b/locale/de/all index f25d6372f..d83821a12 100644 --- a/locale/de/all +++ b/locale/de/all @@ -2,6 +2,8 @@ # -*- coding: utf-8; -*- # vim: fenc=UTF-8 +use utf8; + # These are all the texts to build the translations files. # The file has the form of 'english text' => 'foreign text', # you can add the translation in this file or in the 'missing' file @@ -153,7 +155,6 @@ $self->{texts} = { 'Add bank account' => 'Bankkonto erfassen', 'Add custom variable' => 'Benutzerdefinierte Variable erfassen', 'Add note' => 'Notiz erfassen', - 'Add to group' => 'Zu Gruppe hinzufügen', 'Add unit' => 'Einheit hinzufügen', 'Address' => 'Adresse', 'Administration' => 'Administration', @@ -1011,8 +1012,6 @@ $self->{texts} = { 'May ' => 'Mai', 'May set the BCC field when sending emails' => 'Beim Verschicken von Emails das Feld \'BCC\' setzen', 'Medium Number' => 'Datenträgernummer', - 'Members not of' => 'Benutzer nicht in Gruppe', - 'Members of' => 'Benutzer in Gruppe', 'Memo' => 'Memo', 'Menu' => 'Menü', 'Message' => 'Nachricht', diff --git a/locale/de_DE/all b/locale/de_DE/all index 60afbed2d..9cf56b7c6 100644 --- a/locale/de_DE/all +++ b/locale/de_DE/all @@ -2,6 +2,8 @@ # -*- coding: utf-8; -*- # vim: fenc=UTF-8 +use utf8; + # These are all the texts to build the translations files. # The file has the form of 'english text' => 'foreign text', # you can add the translation in this file or in the 'missing' file diff --git a/locale/en/all b/locale/en/all index e562295db..461e7dce6 100644 --- a/locale/en/all +++ b/locale/en/all @@ -2,6 +2,8 @@ # -*- coding: utf-8; -*- # vim: fenc=UTF-8 +use utf8; + # These are all the texts to build the translations files. # The file has the form of 'english text' => 'foreign text', # you can add the translation in this file or in the 'missing' file diff --git a/scripts/locales.pl b/scripts/locales.pl index 25579c3ea..ff2638b62 100755 --- a/scripts/locales.pl +++ b/scripts/locales.pl @@ -600,12 +600,12 @@ sub generate_file { my $data_name = $params{data_name}; my @delim = split //, ($params{delim} || '{}'); - open my $fh, '>', $file or die "$! : $file"; + open my $fh, '>:encoding(utf8)', $file or die "$! : $file"; $charset =~ s/\r?\n//g; my $emacs_charset = lc $charset; - print $fh "#!/usr/bin/perl\n# -*- coding: $emacs_charset; -*-\n# vim: fenc=$charset\n\n"; + print $fh "#!/usr/bin/perl\n# -*- coding: $emacs_charset; -*-\n# vim: fenc=$charset\n\nuse utf8;\n\n"; print $fh $header, "\n" if $header; print $fh "$data_name = $delim[0]\n" if $data_name;