File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed
opengrok-indexer/src/main/java/org/opengrok/indexer/index Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change 26
26
27
27
import java .io .File ;
28
28
import java .io .IOException ;
29
+ import java .io .PrintStream ;
29
30
import java .lang .reflect .Field ;
30
31
import java .lang .reflect .InvocationTargetException ;
31
32
import java .net .URI ;
@@ -145,12 +146,11 @@ public static void main(String[] argv) {
145
146
try {
146
147
argv = parseOptions (argv );
147
148
if (help ) {
148
- status = 1 ;
149
- System . err .println (helpUsage );
149
+ PrintStream helpStream = status != 0 ? System . err : System . out ;
150
+ helpStream .println (helpUsage );
150
151
if (helpDetailed ) {
151
- System .err .println (AnalyzerGuruHelp .getUsage ());
152
- System .err .println (
153
- ConfigurationHelp .getSamples ());
152
+ helpStream .println (AnalyzerGuruHelp .getUsage ());
153
+ helpStream .println (ConfigurationHelp .getSamples ());
154
154
}
155
155
System .exit (status );
156
156
}
@@ -414,7 +414,7 @@ public static String[] parseOptions(String[] argv) throws ParseException {
414
414
415
415
if (argv .length == 0 ) {
416
416
argv = usage ; // will force usage output
417
- status = 1 ;
417
+ status = 1 ; // with non-zero EXIT STATUS
418
418
}
419
419
420
420
/*
You can’t perform that action at this time.
0 commit comments