File tree Expand file tree Collapse file tree
tree_shaker/src/main/java/com/google/devtools/treeshaker Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -153,6 +153,7 @@ public static void version() {
153153
154154 public static Options parse (String [] args ) throws IOException {
155155 Options options = new Options ();
156+ boolean printArgs = false ;
156157
157158 int nArg = 0 ;
158159 while (nArg < args .length ) {
@@ -204,6 +205,8 @@ public static Options parse(String[] args) throws IOException {
204205 version ();
205206 } else if (arg .equals ("-Werror" )) {
206207 options .treatWarningsAsErrors = true ;
208+ } else if (arg .equals ("-Xprint-args" )) {
209+ printArgs = true ;
207210 } else if (arg .startsWith ("-h" ) || arg .equals ("--help" )) {
208211 help (false );
209212 } else if (arg .startsWith ("-" )) {
@@ -220,6 +223,10 @@ public static Options parse(String[] args) throws IOException {
220223 if (options .sourceFiles .isEmpty ()) {
221224 usage ("no source files" );
222225 }
226+ if (printArgs ) {
227+ System .err .print ("tree_shaker " );
228+ System .err .println (String .join (" " , args ));
229+ }
223230
224231 return options ;
225232 }
You can’t perform that action at this time.
0 commit comments