flex-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aha...@apache.org
Subject [5/8] git commit: [flex-asjs] [refs/heads/develop] - check in READMe and temporary install/deploy scripts
Date Tue, 19 Nov 2013 20:40:25 GMT
check in READMe and temporary install/deploy scripts


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

Branch: refs/heads/develop
Commit: f9c75247f0b4baf916db1a3206ca0c9bf8b43fcf
Parents: 9ef7a2c
Author: Alex Harui <aharui@apache.org>
Authored: Mon Nov 18 21:49:29 2013 -0800
Committer: Alex Harui <aharui@apache.org>
Committed: Mon Nov 18 21:49:29 2013 -0800

----------------------------------------------------------------------
 READme                    |  11 ++++
 scripts/deploy.bat        | 145 +++++++++++++++++++++++++++++++++++++++++
 scripts/deploy.sh         | 124 +++++++++++++++++++++++++++++++++++
 scripts/setuplaunches.bat | 116 +++++++++++++++++++++++++++++++++
 scripts/setuplaunches.sh  | 113 ++++++++++++++++++++++++++++++++
 5 files changed, 509 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/f9c75247/READme
----------------------------------------------------------------------
diff --git a/READme b/READme
new file mode 100644
index 0000000..7c2986c
--- /dev/null
+++ b/READme
@@ -0,0 +1,11 @@
+FlexJS is a prototype of a new Flex framework that can be cross-compiled and produce an HTML/JS/CSS
application that runs in any browser without Flash.
+
+We have prototypes of a List, Button, Label, DropDownList, CheckBox, RadioButton, TextArea,
and TextInput 
We have a prototype of a HTTPService and a LazyCollection 
+
The best way to get started is to follow the instructions from https://cwiki.apache.org/confluence/display/FLEX/Using+FlexJS+with+Adobe+Flash+Builder.
 When you have completed the setup also complete the steps on that wiki page under "Creating
a FlexJS Application".  It is currently easier to modify the existing application example
than to create a new application from scratch.

Building and Running/Debugging

As you edit
the code, the regular Flex compiler is compiling and reporting errors, but it only knows how
to build Flex SWFs so the output SWF probably won't run.  So, before you debug, select the
main MXML file in Package Explorer, choose from the Run menu the new External Tool: "FlexJS
(Debug Build)".  This will run the Falcon compiler with the right options to generate a SWF
in the bin-debug folder that overwrites the one that is there.  Then you should be able to
set breakpoints and debug.

Once you have your app working as a SWF, try the FalconJX External
Tool.  It will o
 utput a debug version to bin/js-debug and a minified version to bin/js-release.   Run the
index.html in any browser.  Some browsers may require that you deploy to a server otherwise
the network calls won't work.

I'm sure there will be lots of issues, but feel free to comment
or contribute.  Remember, this is in its infancy so it will likely fall down easily and poop
unexpectedly.
+
+Using COMPC for Libraries
+
+As before, COMPC is used for building SWCs.  If you don't have any MXML in your SWC, you
can just use a regular Flex Library Project to create the SWC.  If you have MXML in the SWC,
then you will need to use a "FlexJS (COMPC)" external tool.  Once you have a SWC, you can
then try the "FlexJS (JS COMPC)" external tool to cross compile the SWC into a folder of JS
files in folder called "js" in the project's folder.  These JS files are not packaged into
a SWC or ZIP.
+
+Then, to build an application using a library, you would include the SWC in your library
path, and for the "FlexJS (FalconX �)" configuration, you add the SWC in the library-path
and then add a -sdk-js-lib option that points to the "js" folder in the SWC project.
+
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/f9c75247/scripts/deploy.bat
----------------------------------------------------------------------
diff --git a/scripts/deploy.bat b/scripts/deploy.bat
new file mode 100755
index 0000000..a0b0eb8
--- /dev/null
+++ b/scripts/deploy.bat
@@ -0,0 +1,145 @@
+rem  Licensed to the Apache Software Foundation (ASF) under one or more
+
+rem  contributor license agreements.  See the NOTICE file distributed with
+
+rem  this work for additional information regarding copyright ownership.
+
+rem  The ASF licenses this file to You under the Apache License, Version 2.0
+
+rem  (the "License"); you may not use this file except in compliance with
+
+rem  the License.  You may obtain a copy of the License at
+
+rem
+rem     http:\\www.apache.org\licenses\LICENSE-2.0
+
+rem
+rem  Unless required by applicable law or agreed to in writing, software
+
+rem  distributed under the License is distributed on an "AS IS" BASIS,
+
+rem  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+
+rem  See the License for the specific language governing permissions and
+
+rem  limitations under the License.
+
+
+
+if "%~1" == "" goto error
+goto check2
+:error
+echo Usage: deploy.bat [absolute path to Apache Flex SDK] [absolute path to new folder]
+goto end
+
+:check2
+if "%~2" == "" goto error
+if "%GOOG_HOME%" == "" goto nogoog
+goto checkjava
+
+:nogoog
+echo GOOG_HOME environment variable not set.  Set to folder (usually called library) containing
closure folder from Google Closure library
+goto end
+
+:checkjava
+if "%JAVA_HOME%" == "" goto nojava
+goto copyfiles
+
+:nojava
+echo JAVA_HOME environment variable not set.  Set to folder containing bin\java.exe
+goto end
+
+:copyfiles
+echo "Copying Apache Flex SDK (be patient, lots of files)..."
+md %2
+xcopy /s %1\*.* %2
+
+echo %~d0%~p0
+setlocal
+set BASEDIR=%~d0%~p0
+echo Installing FlexJS files from %BASEDIR% to %2
+
+echo removing Flex files
+del /q %2\ant\lib\*.*
+del /q %2\bin\*.*
+del %2\lib\asc.jar
+del %2\lib\asdoc.jar
+del %2\lib\batik-all-flex.jar
+del %2\lib\compc.jar
+del %2\lib\copylocale.jar
+del %2\lib\digest.jar
+del %2\lib\fcsh.jar
+del %2\lib\fdb.jar
+del %2\lib\flex-compiler-oem.jar
+del %2\lib\fxgutils.jar
+del /q %2\lib\mxmlc_*.jar
+del %2\lib\optimizer.jar
+del %2\lib\swcdepends.jar
+del %2\lib\swfdump.jar
+del %2\lib\swfutils.jar
+del %2\lib\velocity-dep-1.4-flex.jar
+
+del /q /s %2\lib\external\*.*
+rd /q /s %2\lib\external
+del %2\flex-sdk-description.xml
+del %2\frameworks\flex-config.xml
+del /q %2\frameworks\libs\automation\*.*
+rd /q %2\frameworks\libs\automation
+del /q %2\frameworks\libs\mobile\*.*
+rd /q %2\frameworks\libs\mobile
+del /q %2\frameworks\libs\mx\*.*
+rem rd %2\frameworks\libs\mx  FB needs this
+
+
del /q %2\frameworks\libs\*.*
+
+
+
+
+
+echo copying Falcon files"
+xcopy /y /s "%BASEDIR%\ant\lib\*.*" %2\ant\lib
+
+xcopy /y /s "%BASEDIR%\bin\*.*" %2\bin
+
+md %2\bin-legacy
+
+xcopy /y /s "%BASEDIR%\bin-legacy\*.*" %2\bin-legacy
+
+xcopy /y /s "%BASEDIR%\lib\*.*" %2\lib
+
+
+echo copying FalconJS files
+
+md %2\js
+
+xcopy /y /s "%BASEDIR%\js\*.*" %2\js
+
+
+echo copying FlexJS files
+
+xcopy /y /s "%BASEDIR%\frameworks\libs\*.*" %2\frameworks\libs
+
+md %2\frameworks\as
+mkdir %2\frameworks\as\src
+
+xcopy /y /s "%BASEDIR%\frameworks\src\*.*" %2\frameworks\as\src
+
+
+move %2\frameworks\as\src\basic-manifest.xml %2\frameworks
+
+move %2\frameworks\as\src\html5-manifest.xml %2\frameworks
+
+move %2\frameworks\as\src\flex-sdk-description.xml %2
+
+move %2\frameworks\as\src\flex-config.xml %2\frameworks
+
+
+endlocal
+
+copy %1\bin\adl.* %2\bin
+copy %1\bin\adt.* %2\bin
+
+setuplaunches.bat %2 "%JAVA_HOME%\bin\java.exe"
+
+:end
+

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/f9c75247/scripts/deploy.sh
----------------------------------------------------------------------
diff --git a/scripts/deploy.sh b/scripts/deploy.sh
new file mode 100755
index 0000000..271e4c4
--- /dev/null
+++ b/scripts/deploy.sh
@@ -0,0 +1,124 @@
+#!/bin/bash
+################################################################################
+##
+##  Licensed to the Apache Software Foundation (ASF) under one or more
+##  contributor license agreements.  See the NOTICE file distributed with
+##  this work for additional information regarding copyright ownership.
+##  The ASF licenses this file to You under the Apache License, Version 2.0
+##  (the "License"); you may not use this file except in compliance with
+##  the License.  You may obtain a copy of the License at
+##
+##      http://www.apache.org/licenses/LICENSE-2.0
+##
+##  Unless required by applicable law or agreed to in writing, software
+##  distributed under the License is distributed on an "AS IS" BASIS,
+##  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+##  See the License for the specific language governing permissions and
+##  limitations under the License.
+##
+################################################################################
+
+i=0
+argv=()
+for arg in "$@"; do
+    argv[$i]="$arg"
+    i=$((i + 1))
+done
+
+if [ "${argv[0]}" = "" ] 
+    then
+    echo "Usage: deploy.sh <path to existing Apache Flex SDK> <path to new folder>"
+    exit
+fi
+if [ "${argv[1]}" = "" ] 
+    then
+    echo "Usage: deploy.sh <path to existing Apache Flex SDK> <path to new folder>"
+    exit
+fi
+if [ -d "${argv[1]}" ]
+    then
+    echo "Error: folder already exists"
+    exit
+fi
+if [ "$GOOG_HOME" = "" ]
+    then
+	echo "GOOG_HOME environment variable not set.  Set to folder (usually called library) containing
closure folder from Google Closure library"
+	exit
+fi
+if [ "$JAVA_HOME" = "" ]
+    then
+	JAVA_HOME="/System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home"
+fi
+
+echo "Copying Apache Flex SDK (be patient, lots of files)..."
+mkdir -pv "${argv[1]}"
+if [ ! -d "${argv[1]}" ]
+    then
+    echo "Error: creating destination folder '${argv[1]}'"
+    exit
+fi
+DESTDIR=`cd "${argv[1]}"; pwd`
+cp -r "${argv[0]}"/* "$DESTDIR"
+
+BASEDIR=$(dirname $0)
+echo "Installing FlexJS files from $BASEDIR to $DESTDIR"
+
+echo "Removing Flex files"
+rm -f "$DESTDIR/ant/lib"/*
+rm "$DESTDIR/bin"/*
+rm "$DESTDIR/lib/asc.jar"
+rm "$DESTDIR/lib/asdoc.jar"
+rm "$DESTDIR/lib/batik-all-flex.jar"
+rm "$DESTDIR/lib/compc.jar"
+rm "$DESTDIR/lib/copylocale.jar"
+rm "$DESTDIR/lib/digest.jar"
+rm "$DESTDIR/lib/fcsh.jar"
+rm "$DESTDIR/lib/fdb.jar"
+rm "$DESTDIR/lib/flex-compiler-oem.jar"
+rm "$DESTDIR/lib/fxgutils.jar"
+rm "$DESTDIR/lib"/mxmlc_*.jar
+rm "$DESTDIR/lib/optimizer.jar"
+rm "$DESTDIR/lib/swcdepends.jar"
+rm "$DESTDIR/lib/swfdump.jar"
+rm "$DESTDIR/lib/swfutils.jar"
+rm "$DESTDIR/lib/velocity-dep-1.4-flex.jar"
+rm -r "$DESTDIR/lib/external"/*
+rmdir "$DESTDIR/lib/external"
+rm "$DESTDIR/flex-sdk-description.xml"
+rm "$DESTDIR/frameworks/flex-config.xml"
+rm "$DESTDIR/frameworks/libs/automation"/*
+rmdir "$DESTDIR/frameworks/libs/automation"
+rm "$DESTDIR/frameworks/libs/mobile"/*
+rmdir "$DESTDIR/frameworks/libs/mobile"
+rm "$DESTDIR/frameworks/libs/mx"/*
+# rmdir "$DESTDIR/frameworks/libs/mx"  FB needs this
+rm "$DESTDIR/frameworks/libs"/*
+
+echo "Copying Falcon files"
+mkdir -p "$DESTDIR/ant/lib"
+cp -r "$BASEDIR/ant/lib"/* "$DESTDIR/ant/lib"
+cp -r "$BASEDIR/bin"/* "$DESTDIR/bin"
+mkdir "$DESTDIR/bin-legacy"
+cp -r "$BASEDIR/bin-legacy"/* "$DESTDIR/bin-legacy"
+cp -r "$BASEDIR/lib"/* "$DESTDIR/lib"
+
+echo "Copying FalconJS files"
+mkdir "$DESTDIR/js"
+cp -r "$BASEDIR/js"/* "$DESTDIR/js"
+
+echo "Copying FlexJS files"
+cp -r "$BASEDIR/frameworks/libs"/* "$DESTDIR/frameworks/libs"
+mkdir "$DESTDIR/frameworks/as"
+mkdir "$DESTDIR/frameworks/as/src"
+cp -r "$BASEDIR/frameworks/src"/* "$DESTDIR/frameworks/as/src"
+
+mv "$DESTDIR/frameworks/as/src/basic-manifest.xml" "$DESTDIR/frameworks"
+mv "$DESTDIR/frameworks/as/src/html5-manifest.xml" "$DESTDIR/frameworks"
+mv "$DESTDIR/frameworks/as/src/flex-sdk-description.xml" "$DESTDIR"
+mv "$DESTDIR/frameworks/as/src/flex-config.xml" "$DESTDIR/frameworks"
+
+# needed for AIR apps
+cp "${argv[0]}/bin/adl" "$DESTDIR/bin"
+cp "${argv[0]}/bin/adt" "$DESTDIR/bin"
+
+./setuplaunches.sh "$DESTDIR" $JAVA_HOME/bin/java

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/f9c75247/scripts/setuplaunches.bat
----------------------------------------------------------------------
diff --git a/scripts/setuplaunches.bat b/scripts/setuplaunches.bat
new file mode 100755
index 0000000..c01af14
--- /dev/null
+++ b/scripts/setuplaunches.bat
@@ -0,0 +1,116 @@
+@echo off
+rem  Licensed to the Apache Software Foundation (ASF) under one or more
+
+rem  contributor license agreements.  See the NOTICE file distributed with
+
+rem  this work for additional information regarding copyright ownership.
+
+rem  The ASF licenses this file to You under the Apache License, Version 2.0
+
+rem  (the "License"); you may not use this file except in compliance with
+
+rem  the License.  You may obtain a copy of the License at
+
+rem
+rem     http:\\www.apache.org\licenses\LICENSE-2.0
+
+rem
+rem  Unless required by applicable law or agreed to in writing, software
+
+rem  distributed under the License is distributed on an "AS IS" BASIS,
+
+rem  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+
+rem  See the License for the specific language governing permissions and
+
+rem  limitations under the License.
+
+
+if "%~1" == "" goto usage
+goto check2
+
+:usage
+echo Usage: setuplaunches <absolute path to Apache Flex SDK> <absolute path to Java
executable>
+goto exit
+
+:check2
+if "%~2" == "" goto usage
+if "%GOOG_HOME%" == "" goto nogoog
+goto doit
+
+:nogoog
+echo GOOG_HOME environment variable not set.  Set to folder (usually called library) containing
closure folder from Google Closure library
+goto exit
+
+:doit
+echo %~d0%~p0
+setlocal
+set BASEDIR=%~d0%~p0
+set FILENAME=FlexJS (Debug Build).launch
+echo Creating FlexJS Debug Launch Configuration
+echo ^<?xml version='1.0' encoding='UTF-8' standalone='no'?^> > "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<launchConfiguration type='org.eclipse.ui.externaltools.ProgramLaunchConfigurationType'^>
>> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<booleanAttribute key='org.eclipse.debug.core.appendEnvironmentVariables' value='false'/^>
>> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<listAttribute key='org.eclipse.debug.ui.favoriteGroups'^> >> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<listEntry value='org.eclipse.ui.externaltools.launchGroup'/^> >> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^</listAttribute^> >> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<stringAttribute key='org.eclipse.ui.externaltools.ATTR_LAUNCH_CONFIGURATION_BUILD_SCOPE'
value='${project}'/^> >> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<stringAttribute key='org.eclipse.ui.externaltools.ATTR_LOCATION' value='%~2'/^>
>> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<stringAttribute key='org.eclipse.ui.externaltools.ATTR_TOOL_ARGUMENTS' value='-Xmx384m
-Dsun.io.useCanonCaches=false -Dflexcompiler=^&quot;%~1^&quot; -Dflexlib=^&quot;%~1\frameworks^&quot;
-jar %~1\lib\falcon-mxmlc.jar -compiler.mxml.children-as-data -debug -compiler.binding-value-change-event=org.apache.flex.events.ValueChangeEvent
-compiler.binding-value-change-event-kind=org.apache.flex.events.ValueChangeEvent -compiler.binding-value-change-event-type=valueChange
-fb ^&quot;${project_loc}^&quot;'/^> >> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^</launchConfiguration^> >> "%~1\ide\flashbuilder\%FILENAME%"
+
+set FILENAME=FlexJS (Release Build).launch
+echo Creating FlexJS Release Launch Configuration
+echo ^<?xml version='1.0' encoding='UTF-8' standalone='no'?^> > "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<launchConfiguration type='org.eclipse.ui.externaltools.ProgramLaunchConfigurationType'^>
>> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<booleanAttribute key='org.eclipse.debug.core.appendEnvironmentVariables' value='false'/^>
>> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<listAttribute key='org.eclipse.debug.ui.favoriteGroups'^> >> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<listEntry value='org.eclipse.ui.externaltools.launchGroup'/^> >> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^</listAttribute^> >> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<stringAttribute key='org.eclipse.ui.externaltools.ATTR_LAUNCH_CONFIGURATION_BUILD_SCOPE'
value='${project}'/^> >> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<stringAttribute key='org.eclipse.ui.externaltools.ATTR_LOCATION' value='%~2'/^>
>> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<stringAttribute key='org.eclipse.ui.externaltools.ATTR_TOOL_ARGUMENTS' value='-Xmx384m
-Dsun.io.useCanonCaches=false -Dflexcompiler=^&quot;%~1^&quot; -Dflexlib=^&quot;%~1\frameworks^&quot;
-jar %~1\lib\falcon-mxmlc.jar -compiler.mxml.children-as-data -compiler.binding-value-change-event=org.apache.flex.events.ValueChangeEvent
-compiler.binding-value-change-event-kind=org.apache.flex.events.ValueChangeEvent -compiler.binding-value-change-event-type=valueChange
-fb ^&quot;${project_loc}^&quot;'/^> >> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^</launchConfiguration^> >> "%~1\ide\flashbuilder\%FILENAME%"
+
+set FILENAME=FlexJS (FalconJX Debug and Release Build).launch
+echo Creating FlexJS FalconJX Launch Configuration
+echo ^<?xml version='1.0' encoding='UTF-8' standalone='no'?^> > "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<launchConfiguration type='org.eclipse.ui.externaltools.ProgramLaunchConfigurationType'^>
>> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<booleanAttribute key='org.eclipse.debug.core.appendEnvironmentVariables' value='false'/^>
>> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<listAttribute key='org.eclipse.debug.ui.favoriteGroups'^> >> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<listEntry value='org.eclipse.ui.externaltools.launchGroup'/^> >> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^</listAttribute^> >> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<stringAttribute key='org.eclipse.ui.externaltools.ATTR_LAUNCH_CONFIGURATION_BUILD_SCOPE'
value='${project}'/^> >> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<stringAttribute key='org.eclipse.ui.externaltools.ATTR_LOCATION' value='%~2'/^>
>> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<stringAttribute key='org.eclipse.ui.externaltools.ATTR_TOOL_ARGUMENTS' value='-Xmx384m
-Dfile.encoding=UTF8 -Dsun.io.useCanonCaches=false -Dflexcompiler=^&quot;%~1^&quot;
-Dflexlib=^&quot;%~1\frameworks^&quot; -jar %~1\js\lib\mxmlc.jar -compiler.mxml.children-as-data
-compiler.binding-value-change-event-type=valueChange -js-output-type=FLEXJS -closure-lib=%GOOG_HOME%
-sdk-js-lib=%~1\js\src -fb ^&quot;${project_loc}^&quot;'/^> >> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^</launchConfiguration^> >> "%~1\ide\flashbuilder\%FILENAME%"
+
+set FILENAME=FlexJS (COMPC).launch
+echo Creating FlexJS COMPC Configuration
+echo ^<?xml version='1.0' encoding='UTF-8' standalone='no'?^> > "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<launchConfiguration type='org.eclipse.ui.externaltools.ProgramLaunchConfigurationType'^>
>> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<booleanAttribute key='org.eclipse.debug.core.appendEnvironmentVariables' value='false'/^>
>> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<listAttribute key='org.eclipse.debug.ui.favoriteGroups'^> >> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<listEntry value='org.eclipse.ui.externaltools.launchGroup'/^> >> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^</listAttribute^> >> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<stringAttribute key='org.eclipse.ui.externaltools.ATTR_LAUNCH_CONFIGURATION_BUILD_SCOPE'
value='${project}'/^> >> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<stringAttribute key='org.eclipse.ui.externaltools.ATTR_LOCATION' value='%~2'/^>
>> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<stringAttribute key='org.eclipse.ui.externaltools.ATTR_TOOL_ARGUMENTS' value='-Xmx384m
-Dsun.io.useCanonCaches=false -Dflexcompiler=^&quot;%~1^&quot; -Dflexlib=^&quot;%~1\frameworks^&quot;
-jar %~1\lib\falcon-compc.jar -compiler.mxml.children-as-data -debug -compiler.binding-value-change-event=org.apache.flex.events.ValueChangeEvent
-compiler.binding-value-change-event-kind=org.apache.flex.events.ValueChangeEvent -compiler.binding-value-change-event-type=valueChange
-fb ^&quot;${project_loc}^&quot;'/^> >> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^</launchConfiguration^> >> "%~1\ide\flashbuilder\%FILENAME%"
+
+set FILENAME=FlexJS (JS COMPC).launch
+echo Creating FlexJS JS COMPC Launch Configuration
+echo ^<?xml version='1.0' encoding='UTF-8' standalone='no'?^> > "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<launchConfiguration type='org.eclipse.ui.externaltools.ProgramLaunchConfigurationType'^>
>> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<booleanAttribute key='org.eclipse.debug.core.appendEnvironmentVariables' value='false'/^>
>> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<listAttribute key='org.eclipse.debug.ui.favoriteGroups'^> >> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<listEntry value='org.eclipse.ui.externaltools.launchGroup'/^> >> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^</listAttribute^> >> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<stringAttribute key='org.eclipse.ui.externaltools.ATTR_LAUNCH_CONFIGURATION_BUILD_SCOPE'
value='${project}'/^> >> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<stringAttribute key='org.eclipse.ui.externaltools.ATTR_LOCATION' value='%~2'/^>
>> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^<stringAttribute key='org.eclipse.ui.externaltools.ATTR_TOOL_ARGUMENTS' value='-Xmx384m
-Dfile.encoding=UTF8 -Dsun.io.useCanonCaches=false -Dflexcompiler=^&quot;%~1^&quot;
-Dflexlib=^&quot;%~1\frameworks^&quot; -jar %~1\js\lib\mxmlc.jar -compiler.mxml.children-as-data
-compiler.binding-value-change-event-type=valueChange -js-output-type=FLEXJS -closure-lib=%GOOG_HOME%
-sdk-js-lib=%~1\js\src -fb ^&quot;${project_loc}^&quot;'/^> >> "%~1\ide\flashbuilder\%FILENAME%"
+echo ^</launchConfiguration^> >> "%~1\ide\flashbuilder\%FILENAME%"
+
+endlocal
+:exit
+

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/f9c75247/scripts/setuplaunches.sh
----------------------------------------------------------------------
diff --git a/scripts/setuplaunches.sh b/scripts/setuplaunches.sh
new file mode 100755
index 0000000..443ba45
--- /dev/null
+++ b/scripts/setuplaunches.sh
@@ -0,0 +1,113 @@
+#!/bin/bash
+################################################################################
+##
+##  Licensed to the Apache Software Foundation (ASF) under one or more
+##  contributor license agreements.  See the NOTICE file distributed with
+##  this work for additional information regarding copyright ownership.
+##  The ASF licenses this file to You under the Apache License, Version 2.0
+##  (the "License"); you may not use this file except in compliance with
+##  the License.  You may obtain a copy of the License at
+##
+##      http://www.apache.org/licenses/LICENSE-2.0
+##
+##  Unless required by applicable law or agreed to in writing, software
+##  distributed under the License is distributed on an "AS IS" BASIS,
+##  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+##  See the License for the specific language governing permissions and
+##  limitations under the License.
+##
+################################################################################
+
+i=0
+argv=()
+for arg in "$@"; do
+    argv[$i]="$arg"
+    i=$((i + 1))
+done
+
+if [ "${argv[0]}" = "" ] 
+    then
+    echo "Usage: setuplaunches <absolute path to Apache Flex SDK> <absolute path
to Java executable>"
+    exit
+fi
+if [ "${argv[1]}" = "" ] 
+    then
+    echo "Usage: setuplaunches <absolute path to Apache Flex SDK> <absolute path
to Java executable>"
+    exit
+fi
+if [ ! -d "${argv[0]}/frameworks/" ]
+    then
+    echo "Error: not a valid SDK directory"
+    exit
+fi
+if [ "$GOOG_HOME" = "" ]
+    then
+	echo "GOOG_HOME environment variable not set.  Set to folder (usually called library) containing
closure folder from Google Closure library"
+	exit
+fi
+
+BASEDIR=$(dirname $0)
+FILENAME="FlexJS (Debug Build).launch"
+echo "Creating FlexJS Debug Launch Configuration"
+echo "<?xml version='1.0' encoding='UTF-8' standalone='no'?>" > "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<launchConfiguration type='org.eclipse.ui.externaltools.ProgramLaunchConfigurationType'>"
>> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<booleanAttribute key='org.eclipse.debug.core.appendEnvironmentVariables' value='false'/>"
>> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<listAttribute key='org.eclipse.debug.ui.favoriteGroups'>" >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<listEntry value='org.eclipse.ui.externaltools.launchGroup'/>" >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "</listAttribute>" >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<stringAttribute key='org.eclipse.ui.externaltools.ATTR_LAUNCH_CONFIGURATION_BUILD_SCOPE'
value='\${project}'/>" >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<stringAttribute key='org.eclipse.ui.externaltools.ATTR_LOCATION' value='${argv[1]}'/>"
>> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<stringAttribute key='org.eclipse.ui.externaltools.ATTR_TOOL_ARGUMENTS' value='-Xmx384m
-Dsun.io.useCanonCaches=false -Dflexcompiler=&quot;${argv[0]}&quot; -Dflexlib=&quot;${argv[0]}/frameworks&quot;
-jar &quot;${argv[0]}/lib/falcon-mxmlc.jar&quot; -compiler.mxml.children-as-data -debug
-compiler.binding-value-change-event=org.apache.flex.events.ValueChangeEvent -compiler.binding-value-change-event-kind=org.apache.flex.events.ValueChangeEvent
-compiler.binding-value-change-event-type=valueChange -fb &quot;\${project_loc}&quot;'/>"
>> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "</launchConfiguration>"  >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+
+FILENAME="FlexJS (Release Build).launch"
+echo "Creating FlexJS Release Launch Configuration"
+echo "<?xml version='1.0' encoding='UTF-8' standalone='no'?>" > "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<launchConfiguration type='org.eclipse.ui.externaltools.ProgramLaunchConfigurationType'>"
>> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<booleanAttribute key='org.eclipse.debug.core.appendEnvironmentVariables' value='false'/>"
>> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<listAttribute key='org.eclipse.debug.ui.favoriteGroups'>" >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<listEntry value='org.eclipse.ui.externaltools.launchGroup'/>" >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "</listAttribute>" >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<stringAttribute key='org.eclipse.ui.externaltools.ATTR_LAUNCH_CONFIGURATION_BUILD_SCOPE'
value='\${project}'/>" >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<stringAttribute key='org.eclipse.ui.externaltools.ATTR_LOCATION' value='${argv[1]}'/>"
>> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<stringAttribute key='org.eclipse.ui.externaltools.ATTR_TOOL_ARGUMENTS' value='-Xmx384m
-Dsun.io.useCanonCaches=false -Dflexcompiler=&quot;${argv[0]}&quot; -Dflexlib=&quot;${argv[0]}/frameworks&quot;
-jar &quot;${argv[0]}/lib/falcon-mxmlc.jar&quot; -compiler.mxml.children-as-data -compiler.binding-value-change-event=org.apache.flex.events.ValueChangeEvent
-compiler.binding-value-change-event-kind=org.apache.flex.events.ValueChangeEvent -compiler.binding-value-change-event-type=valueChange
-fb &quot;\${project_loc}&quot;'/>" >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "</launchConfiguration>"  >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+
+FILENAME="FlexJS (FalconJX Debug and Release Build).launch"
+echo "Creating FlexJS FalconJX Launch Configuration"
+echo "<?xml version='1.0' encoding='UTF-8' standalone='no'?>" > "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<launchConfiguration type='org.eclipse.ui.externaltools.ProgramLaunchConfigurationType'>"
>> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<booleanAttribute key='org.eclipse.debug.core.appendEnvironmentVariables' value='false'/>"
>> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<listAttribute key='org.eclipse.debug.ui.favoriteGroups'>" >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<listEntry value='org.eclipse.ui.externaltools.launchGroup'/>" >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "</listAttribute>" >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<stringAttribute key='org.eclipse.ui.externaltools.ATTR_LAUNCH_CONFIGURATION_BUILD_SCOPE'
value='\${project}'/>" >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<stringAttribute key='org.eclipse.ui.externaltools.ATTR_LOCATION' value='${argv[1]}'/>"
>> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<stringAttribute key='org.eclipse.ui.externaltools.ATTR_TOOL_ARGUMENTS' value='-Xmx384m
-Dfile.encoding=UTF8 -Dsun.io.useCanonCaches=false -Dflexcompiler=&quot;${argv[0]}&quot;
-Dflexlib=&quot;${argv[0]}/frameworks&quot; -jar &quot;${argv[0]}/js/lib/mxmlc.jar&quot;
-compiler.mxml.children-as-data -compiler.binding-value-change-event-type=valueChange -js-output-type=FLEXJS
-closure-lib=&quot;$GOOG_HOME&quot; -sdk-js-lib=&quot;${argv[0]}/js/src&quot;
-fb &quot;\${project_loc}&quot;'/>" >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "</launchConfiguration>"  >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+
+FILENAME="FlexJS (COMPC).launch"
+echo "Creating FlexJS COMPC Launch Configuration"
+echo "<?xml version='1.0' encoding='UTF-8' standalone='no'?>" > "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<launchConfiguration type='org.eclipse.ui.externaltools.ProgramLaunchConfigurationType'>"
>> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<booleanAttribute key='org.eclipse.debug.core.appendEnvironmentVariables' value='false'/>"
>> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<listAttribute key='org.eclipse.debug.ui.favoriteGroups'>" >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<listEntry value='org.eclipse.ui.externaltools.launchGroup'/>" >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "</listAttribute>" >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<stringAttribute key='org.eclipse.ui.externaltools.ATTR_LAUNCH_CONFIGURATION_BUILD_SCOPE'
value='\${project}'/>" >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<stringAttribute key='org.eclipse.ui.externaltools.ATTR_LOCATION' value='${argv[1]}'/>"
>> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<stringAttribute key='org.eclipse.ui.externaltools.ATTR_TOOL_ARGUMENTS' value='-Xmx384m
-Dsun.io.useCanonCaches=false -Dflexcompiler=&quot;${argv[0]}&quot; -Dflexlib=&quot;${argv[0]}/frameworks&quot;
-jar &quot;${argv[0]}/lib/falcon-compc.jar&quot; -debug -compiler.mxml.children-as-data
-compiler.binding-value-change-event=org.apache.flex.events.ValueChangeEvent -compiler.binding-value-change-event-kind=org.apache.flex.events.ValueChangeEvent
-compiler.binding-value-change-event-type=valueChange -fb &quot;\${project_loc}&quot;'
/>" >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "</launchConfiguration>"  >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+
+FILENAME="FlexJS (JS COMPC).launch"
+echo "Creating FlexJS JS COMPC Launch Configuration"
+echo "<?xml version='1.0' encoding='UTF-8' standalone='no'?>" > "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<launchConfiguration type='org.eclipse.ui.externaltools.ProgramLaunchConfigurationType'>"
>> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<booleanAttribute key='org.eclipse.debug.core.appendEnvironmentVariables' value='false'/>"
>> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<listAttribute key='org.eclipse.debug.ui.favoriteGroups'>" >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<listEntry value='org.eclipse.ui.externaltools.launchGroup'/>" >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "</listAttribute>" >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<stringAttribute key='org.eclipse.ui.externaltools.ATTR_LAUNCH_CONFIGURATION_BUILD_SCOPE'
value='\${project}'/>" >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<stringAttribute key='org.eclipse.ui.externaltools.ATTR_LOCATION' value='${argv[1]}'/>"
>> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "<stringAttribute key='org.eclipse.ui.externaltools.ATTR_TOOL_ARGUMENTS' value='-Xmx384m
-Dfile.encoding=UTF8 -Dsun.io.useCanonCaches=false -Dflexcompiler=&quot;${argv[0]}&quot;
-Dflexlib=&quot;${argv[0]}/frameworks&quot; -jar &quot;${argv[0]}/js/lib/compc.jar&quot;
-compiler.mxml.children-as-data -compiler.binding-value-change-event-type=valueChange -js-output-type=FLEXJS
-closure-lib=$GOOG_HOME -sdk-js-lib=${argv[0]}/js/src -fb &quot;\${project_loc}&quot;'
/>" >> "${argv[0]}/ide/flashbuilder/$FILENAME"
+echo "</launchConfiguration>"  >> "${argv[0]}/ide/flashbuilder/$FILENAME"


Mime
View raw message