Skip to content

Commit c0fb28f

Browse files
committed
Show usage when invoked without arguments.
1 parent 4b19855 commit c0fb28f

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/com/yahoo/platform/yui/compressor/YUICompressor.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,10 @@ public static void main(String args[]) {
8181
String[] fileArgs = parser.getRemainingArgs();
8282
java.util.List files = java.util.Arrays.asList(fileArgs);
8383
if (files.isEmpty()) {
84+
if (type == null) {
85+
usage();
86+
System.exit(1);
87+
}
8488
files = new java.util.ArrayList();
8589
files.add("-"); // read from stdin
8690
}

0 commit comments

Comments
 (0)