You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@joshua.apache.org by mj...@apache.org on 2016/11/03 18:51:21 UTC

[2/2] incubator-joshua git commit: shutup!

shutup!


Project: http://git-wip-us.apache.org/repos/asf/incubator-joshua/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-joshua/commit/f23cd091
Tree: http://git-wip-us.apache.org/repos/asf/incubator-joshua/tree/f23cd091
Diff: http://git-wip-us.apache.org/repos/asf/incubator-joshua/diff/f23cd091

Branch: refs/heads/master
Commit: f23cd0917699cadd52ffaac7e12b45071e21bf8e
Parents: 2967b53
Author: Matt Post <po...@cs.jhu.edu>
Authored: Thu Nov 3 14:50:40 2016 -0400
Committer: Matt Post <po...@cs.jhu.edu>
Committed: Thu Nov 3 14:50:40 2016 -0400

----------------------------------------------------------------------
 scripts/preparation/tokenize.pl | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-joshua/blob/f23cd091/scripts/preparation/tokenize.pl
----------------------------------------------------------------------
diff --git a/scripts/preparation/tokenize.pl b/scripts/preparation/tokenize.pl
index 0ae49cd..a5cae8d 100755
--- a/scripts/preparation/tokenize.pl
+++ b/scripts/preparation/tokenize.pl
@@ -49,7 +49,7 @@ if (!$QUIET) {
 
 load_prefixes($language,\%NONBREAKING_PREFIX);
 
-if (scalar(%NONBREAKING_PREFIX) eq 0){
+if (scalar(%NONBREAKING_PREFIX) == 0 && ! $QUIET){
 	print STDERR "Warning: No known abbreviations for language '$language'\n";
 }
 
@@ -262,7 +262,7 @@ sub load_prefixes {
 	#default back to English if we don't have a language-specific prefix file
 	if (!(-e $prefixfile)) {
 		$prefixfile = "$PREFIX_DIR/nonbreaking_prefix.en";
-		print STDERR "WARNING: No known abbreviations for language '$language', attempting fall-back to English version...\n";
+		print STDERR "WARNING: No known abbreviations for language '$language', attempting fall-back to English version...\n" unless $QUIET;
 		die ("ERROR: No abbreviations files found in $PREFIX_DIR\n") unless (-e $prefixfile);
 	}