Supports
Current branches
RequirementsYou should be able to read and understand XML and basic ANT targets.
Set your environment variables, so ant and java are known operations to your system. Note: Currently all wrappers are written for the Flex 3 SDK. Targetssetup targetEach project should define a setup target in the build.xml, that downloads and moves all need libraries of your project to the lib folder. Who ever has to work with the project should be able to satisfy all project dependencies by running this setup once. production targetEach project should define a production target in the build.xml, that builds for production deployment. This target can only be run after successful setup. How ToTurkish Sweater already includes an example code that you should be able to run right away. Download and unzip the project.
If you get an error of a missing report-xml, try running main-target first. The main target will create that file for you. lib and font target are depending on it. Future release we will fix this. Individual Project ValuesTo define host specific settings use the build.properties in the build folder. AUTHOR = You SOME_OS_SPECIFIC_LIB = somewhere.com Shared Project ValuesPlease change the project name in the build file: <project name="XYZ".. Also in the build.xml you should edit the project values in the upper part of the document look for: <!--//////////////////////////////////-->
<!--// properties (Edit if needed) //-->
<!--//////////////////////////////////-->
<!--// Additional libraries (Extend if needed through repeat defining property LIBS) //-->
<!--// Example: <property name="LIBS" value="${LIBS} -source-path ${SOME_LIB}" /> //-->
<property name="LIBS" value="source-path ${PWD}/lib/toolkit" />
<!--// Additional swc import //-->
<!--// Imports only referenced classes, use for sourcecode //-->
<!--// Example: <property name="IMPORT" value="library-path+=${PWD}/lib/some.swc -library-path+=${PWD}/lib/other.swc" /> //-->
<property name="IMPORT" value="-library-path+=${PWD}/lib/lib.swc" />
<!--// Additional swc include //-->
<!--// Includes all containing classes, use for assets //-->
<!--// Example: <property name="INCLUDE" value="-include-libraries=${PWD}/lib/some.swc -include-libraries=${PWD}/lib/other.swc" /> //-->
<property name="INCLUDE" value="-include-libraries=${PWD}/lib/some.swc" />
<!--// Product owner //-->
<property name="PRODUCT.release" value="0" />
<property name="PRODUCT.sprint" value="0" />
<property name="PRODUCT.copyright" value="Copyright(c) Your Company or Client(TM)" />
<property name="PRODUCT.owner" value="http://www.somewhere.com" />
<property name="DEBUG_PASSWORD" value="1234abcd" />Product DetailsTurkish Sweater already compiles a Product class for you, that helps you verifying which version, build, by whom and when created you are actually looking at. Just add two line of codes to your project (in a class that extends Sprite). import product.Product; Product.register(this); And you will find in the trace, context-menu and by pressing the ~ product information. Defining DependenciesCommon InterfaceTurkish Sweater tries to formalize the interface of different methods to retrieve libraries from a server.
Next to these three, others are mostly common shared as well.
Supported MethodsTurkish Sweater currently supports cvs, svn, http, https, secure copy and ftp. GET-CVS GET-FTP GET-HTTP GET-SVN GET-SCP XYZ-AUTHORIZEMethods that require a username and password define mostly two versions of them self:
PropertiesUse ANT properties to define where your third party library lives <!--//////////////////--> <!--// Dependencies //--> <!--//////////////////--> <!--// Flex SDK //--> <property name="SDK-SERVER" value="download.macromedia.com" /> <property name="SDK-FILE" value="pub/flex/sdk/flex_sdk_3.zip" /> TargetDefine your own target to download the libraries, like in the given example of setup-as-libs <GET-HTTP
from="${SDK-SERVER}"
server="${SDK-FILE}"
to="${PWD}/temp/SDK.zip"
/>${PWD}You will have noticed that Turkish Sweater uses the property PWD a lot. The name comes from 'print working directory' and holds the root folder of your project, to enable you relative path definitions. MARCOSTODO: explain all marcos SWF SettingsTurkish Sweater tries to minimize settings inside the build.xml. Use compiler directives to set swf specific settings like framerate and size: [ SWF( backgroundColor="0xFFFFFF", frameRate="100", width="950", height="500") ]
public class Main extends Sprite {
SVN ignoreSince you want to exclude the lib folder from version control, you can use provided svn ignore files. Please type in your working folder: $ svn propset svn:ignore -R -F .svn-ignore-general . $ svn propset svn:ignore -F .svn-ignore-project . To see also the ignored files in your status view type: $ svn status --no-ignore TIPLook into the source code of files, most of them should be well documented. If you miss documentation or find outdated one, please let me know. |