Command Line Build a Flash Builder 4 Premium Feature

Posted on September 15, 2010 | 7 comments

The Flash Builder is great at organizing projects and all the build dependencies that revolve around large projects. Creating build scripts (typically ant build scripts using mxmlc/compc Flex ant tasks) can be complex and hard to recreate all the subtleties of the Flash Builder project build process. There is a new feature that is part of Flash Builder 4 Premium called Command Line Build that might help out in this area. Let me describe the feature first then talk about the issues.

This feature provides a new Adobe ant task called fb.exportReleaseBuild. This task is meant to run in connection with a headless execution of Flash Builder 4 to export your specific project’s release build. Basically this does the same thing as you would in Flash Builder 4 as Export -> Release Build. To use this I provide the example/scripts below for a Flash Builder 4 workspace called “PremiumFeatureWebinar” with a “ExampleApplication” project inside the workspace.

ant build.xml:

<?xml version="1.0"?>
<project default="main">
    <target name="main">
        <fb.exportReleaseBuild project="ExampleApplication" />

Shell Script to run Flash Builder 4 in headless mode on Mac OS (Windows would be similar but a bat/exe file):

# works with either or
"/Applications/Adobe Flash Builder 4/Adobe Flash Builder Flash Builder 4"  --launcher.suppressErrors -noSplash -application org.eclipse.ant.core.antRunner  -data "$WORKSPACE" -file "$(pwd)/build.xml" main

Now the issues, well first you need a copy of a licensed Flash Builder 4 Premium. Which also means it only runs on Windows and Mac OSX, where typically automation builds are done on Linux. Either way its good to be aware of this feature to use in a crunch or for testing other build scripts against a known good release build with Flash Builder 4′s build process.

I show an example of this new feature running along with some other Flash Builder 4 Premium features in a webinar found here.

  • Tom Chiverton

    Well, if the Linux version of Flash Builder wasn’t sat on Labs festering, but was given some love and sold, Linux automation builds wouldn’t be an issue for your customers would it :-)

    • Renaun Erickson


    • Clint Modien

      $700 for a single Flash Builder license to build a project (ya linux guys would LOVE that)… AND if you want to run certain portions of the build in parallel it would require multiple licenses… effectively yielding $700 / thread

      Or you can use ant for $0 / thread.

  • Clint Modien

    Question… what use case does this solve that exporting an ant build file based on the flash builder project wouldn’t satisfy?

    Would love to see the cost analysis breakdown on this feature. How much dev,qa,tech writer time did/does it take to build/maintain this feature vs. how many licenses it would sell. I think exporting an ant build file would sell more licenses. @ashorten

    • Renaun Erickson

      Take the use case of having a complex project of like 10 library projects and getting all the merge code/external settings of RSLs or no RSLs etc… all just right. There was a case that I saw where their build scripts looked just fine but it produced a Verify Error, the export release build in Flash Builder did not produce the error.

      • Clint Modien

        Mmm… You may have reinforced my point. They were using some other build scripts in the first place (ant?). Exporting an ant build would have been more aligned with the current solution.

        In any case I can assure you… exporting an ant build would be more aligned with a substantially higher percentage of production build scenarios.

    • Renaun Erickson

      I agree, and have said so both internally and externally. But for now if you are having troubles with rolling your own complex build scripts with mxmlc/compc ant tasks the Command Line Build feature is an option.

  • Pingback: 2.0 – flash és webfejlesztés » Heti link gy?jtemény 2