From e3ef4f78b9e996c61ab18a8ff90529bb069b3861 Mon Sep 17 00:00:00 2001 From: acli Date: Mon, 23 Feb 2004 20:04:33 +0000 Subject: [PATCH] -v option (undocumented) for more verbose output --- misc/translator/intranet.zh_TW | 3 ++- misc/translator/xgettext.pl | 8 ++++++++ 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/misc/translator/intranet.zh_TW b/misc/translator/intranet.zh_TW index d9c9aa091b..c1c7f52dc4 100644 --- a/misc/translator/intranet.zh_TW +++ b/misc/translator/intranet.zh_TW @@ -5689,11 +5689,12 @@ msgstr "系統偏好管理" msgid "System preferences." msgstr "系統偏好" +# TODO Probably not entirely correct. But probably won't have a real impact. #: ../../koha-tmpl/intranet-tmpl/default/en/value_builder/unimarc_field_700-4.tmpl:6 msgid "" "Sélectionnez la valeur pour le champ 700 $4. Elle sera automatiquement " "reportée dans la zone 700 $8 qui suit." -msgstr "" +msgstr "請選擇欄 700 $4 之值。此值在適當時將會自動在 700 $8 出現。" #: ../../koha-tmpl/intranet-tmpl/default/en/acqui/newbasket2.tmpl:36 #: ../../koha-tmpl/intranet-tmpl/default/en/acqui/recieve.tmpl:26 diff --git a/misc/translator/xgettext.pl b/misc/translator/xgettext.pl index 2da236360f..ee2aa338e0 100755 --- a/misc/translator/xgettext.pl +++ b/misc/translator/xgettext.pl @@ -18,6 +18,7 @@ use vars qw( $extract_all_p ); use vars qw( $pedantic_p ); use vars qw( %text %translation ); use vars qw( $charset_in $charset_out ); +use vars qw( $verbose_p ); ############################################################################### @@ -225,6 +226,7 @@ HTML::Template options: Output details: -s, --sort-output generate sorted output -F, --sort-by-file sort output by file location + -v, --verbose explain what is being done Informative output: --help Display this help and exit @@ -255,6 +257,7 @@ GetOptions( 'output|o=s' => \$output, 's|sort-output' => sub { $sort = 's' }, 'F|sort-by-file' => sub { $sort = 'F' }, + 'v|verbose' => \$verbose_p, 'help' => sub { usage(0) }, ) || usage_error; @@ -269,22 +272,27 @@ usage_error('You cannot specify both --convert-from and --files-from') if defined $convert_from && defined $files_from; if (defined $output && $output ne '-') { + print STDERR "$0: Opening output file \"$output\"\n" if $verbose_p; open(OUTPUT, ">$output") || die "$output: $!\n"; } else { + print STDERR "$0: Outputting to STDOUT...\n" if $verbose_p; open(OUTPUT, ">&STDOUT"); } if (defined $files_from) { + print STDERR "$0: Opening input file list \"$files_from\"\n" if $verbose_p; open(INPUT, "<$files_from") || die "$files_from: $!\n"; while () { chomp; my $h = TmplTokenizer->new( "$directory/$_" ); $h->set_allow_cformat( 1 ); VerboseWarnings::set_input_file_name "$directory/$_"; + print STDERR "$0: Processing file \"$directory/$_\"\n" if $verbose_p; text_extract( $h ); } close INPUT; } else { + print STDERR "$0: Converting \"$convert_from\"\n" if $verbose_p; convert_translation_file; } generate_po_file; -- 2.11.0