added support for --js flag inside -js-compiler-option

Project: http://git-wip-us.apache.org/repos/asf/flex-falcon/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-falcon/commit/9f31b879
Tree: http://git-wip-us.apache.org/repos/asf/flex-falcon/tree/9f31b879
Diff: http://git-wip-us.apache.org/repos/asf/flex-falcon/diff/9f31b879

Branch: refs/heads/develop
Commit: 9f31b8793d3f55ecd6269c8a0e943b064dbe39f5
Parents: 9454495
Author: Andy Dufilie <[email protected]>
Authored: Wed Jan 13 16:38:01 2016 -0500
Committer: Andy Dufilie <[email protected]>
Committed: Wed Jan 13 16:38:01 2016 -0500

----------------------------------------------------------------------
 .../apache/flex/compiler/utils/JSClosureCompilerWrapper.java    | 5 +++++
 1 file changed, 5 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-falcon/blob/9f31b879/compiler.jx/src/org/apache/flex/compiler/utils/JSClosureCompilerWrapper.java
----------------------------------------------------------------------
diff --git 
a/compiler.jx/src/org/apache/flex/compiler/utils/JSClosureCompilerWrapper.java 
b/compiler.jx/src/org/apache/flex/compiler/utils/JSClosureCompilerWrapper.java
index 05e0328..e353dc8 100644
--- 
a/compiler.jx/src/org/apache/flex/compiler/utils/JSClosureCompilerWrapper.java
+++ 
b/compiler.jx/src/org/apache/flex/compiler/utils/JSClosureCompilerWrapper.java
@@ -145,10 +145,15 @@ public class JSClosureCompilerWrapper
     
     private void initOptions(List<String> args)
     {
+       final String JS_FLAG = "--js ";
+       
        boolean hasCompilationLevel = false;
        boolean hasWarningLevel = false;
        for (String s : args)
        {
+               if (s.startsWith(JS_FLAG))
+                       addJSSourceFile(s.substring(JS_FLAG.length()));
+               
                if (s.startsWith("--compilation_level ") ||
                        s.startsWith("-O "))
                        hasCompilationLevel = true;

Reply via email to