A recording of this presentation can be found here:
http://blog.natebeck.net/2009/07/getting-dirty-with-the-flex-sdk-slides-and-recording/
So the Flex SDK is open source now, but what does that mean to you? You are a Flex developer but you have never even looked at the code powering the Flex SDK. This session is focused on Flex veterans as well as beginners who want to get their hands dirty with the inner workings of the Flex SDK. This session will equip you with the knowledge to get started developing for the Flex framework itself.
We will cover the following topics:
- Resources to learn about the inner workings of the Flex SDK (Coding Conventions, Specs, etc...)
- Subversion, ANT, Mustella... What they are, and how they are used with the Flex SDK.
- Obtaining the Flex SDK source code.
- Setting up Flex Builder for working with the Flex SDK.
- Common pitfalls when getting set up.
- Finding bugs to fix
- How to run check-in tests.
- How to submit a patch, creating diff files.
- Getting involved in the community.. BugQuash, reviewing patches, spring cleaning the bug system.
This session will be presented by Nate Beck, one of the creators of BugQuash. Nate is an active member the Flex community, and has first-hand knowledge of the excitement and addiction that is contributing to the Flex SDK.
3. So, Flex is Open Source
We get to make a great product even better.
We have the ability to submit our own fixes.
Collaboration is key for a successful platform.
4. What’s in it for me?
As I’ve already said, Open Source is a good thing. But
there are some other reasons why you should get
involved.
Bragging Rights!
Know the Flex SDK better than 90% of every other Flex
Developer out there.
Free Stuff! The Flex Team will buy you an Adobe related
book for every 3 patches that are accepted.
5. What this talk is about
The tools and processes that are used for development
of the Flex SDK.
Tips and tricks that will make your life easier.
And hopefully, a quick demo.
6. What this talk isn’t about
In-depth Operating System specific setup (with the
exception of some tips).
OpenSource.Adobe.com/flex has excellent resources
for your specific OS.
7. Where to start
Adobe’s Open Source Website
(http://opensource.adobe.com/flex)
Select “Developer Documentation” under the Flex SDK
Project. Then select “Set up your development
environment”.
Tip -- There are links near the bottom of this page for
your specific operating system.
8. What you’ll need
Subversion (command-line or a GUI)
Apache Ant
Java 2 Software Development Kit
Configure your Flash Player
Configure your operating system (Adobe provides a
script to take care of this)
Cygwin (if you’re on Windows, read the Windows
specific setup)
9. Wow Nate, that’s a lot.
It’s not as hard as it seems.
You only need to set this up once on your development
machine.
Let’s dive in.
10. Subversion
Subversion (commonly known as SVN) is an open-
source version control system.
There are two ways you can work with subversion:
You can use the command-line tool.
You can use a GUI.
SmartSVN (mac) || TortiseSVN (win) are good options.
TIP -- Adobe’s OpenSource site assumes you are
using command-line. So we’ll use that in this talk.
11. Ant (Another Neat Tool)
Apache Ant is a software tool for automating software
build processes. It is similar to make but is
implemented using the Java language.
Therefore, it requires the Java platform.
Ant uses “build files” to automate compilation of the
Flex SDK.
12. Java 2 Software
Development Kit
Tip -- Windows users need to follow the Windows
instructions carefully. The Flex SDK build script
assumes that the Java JDK is installed in a very
specific directory.
Tip -- On Mac OS X, Just run Software Update. This
ensures that you have the latest Java binaries. Thanks
Apple.
13. Okay, I think I’m good to go.
Great! Let’s double check our setup. Open up your
command-line. Terminal on Mac, Cygwin on Windows.
ant -version
svn --version
java -version
echo $JAVA_HOME (echo %JAVA_HOME% on
Windows)
14. Sweet... now what?
If that worked, pat
yourself on the back
and get a drink...
because we’re just
getting started.
I’ll wait.
16. Getting the Source Code
Head back to Adobe’s Open Source Flex site
(http://opensource.adobe.com/flex)
Select “Source” under the Flex SDK Project.
TIP -- Use the Flex project skeleton provided on this
page so you don’t have to check out EVERYTHING.
TIP -- Using the “svn up” command will allow you to
select which directories and files you want to
download.
17. Finding bugs
to quash...
(If you don’t have your own)
“Software is by its nature an
imperfect science and often small
defects exist. With enough eyes,
bugs are much easier to see,
understand, and eliminate.”
-- Ted Patrick, Adobe
18. Sign up for Adobe’s Bug
System (JIRA)
Go to Adobe’s Bug website:
http://bugs.adobe.com/flex/
Register if you haven’t already.
This is the site where users come to submit bugs
against the Flex SDK.
This is also the site we use to find relevant bugs for us
to work on.
19. On the hunt for a bug
If you don’t have a “pet” bug in mind already that you
want to work on, you can find one in the Adobe Bug
system.
TIP -- The bug system has a special milestone called
“SDK Community Bug Fix Candidates”. There are bugs
that the Flex Team specifically has asked the
community to fix (http://bit.ly/aEEfa).
20. Become a contributor
Before you can submit a patch, you must become a
contributor.
It’s easy, just fill it out and send it in (but, read it first of
course). Once submitted you will have a new link when
you are logged in to Adobe’s Bug System (JIRA)
called... Submit Patch.
Another perk to being a contributor is you get a
sandbox to play in.
22. Setting up Flex Flash Builder
The Flex SDK Team has been very kind to us... they
have given us all that we need to use Flash Builder to
develop the SDK.
TIP -- When using Flash Builder to develop on the
SDK, remember to add a Linked Resource for
“FLEX_SDK”.
TIP -- If you run into problems when switching
between different versions of the SDK, make sure your
Linked Resource setting is correct.
24. Set Environment Variables
The SDK has scripts that will automatically set your
environment’s variables.
Change to the version of the SDK you are working
with... (ex. 3.x or trunk) and run:
source setup.sh
TIP -- On Windows, you should be running this
command from Cygwin.
(more info here: http://bit.ly/1aNlDp)
25. Configure Flash Player
Follow the steps found on the Open Source site (under
Configure Flash Player on http://bit.ly/1aNlDp) to:
Make changes to or create mm.cfg if it doesn’t exist.
Download FlexSDK.cfg into FlashPlayerTrust.
TIP -- If you run into SecurityErrors you may need to
add more paths to the FlexSDK.cfg file. I had to add /
flex/sdk/branches/3.x and /flex/sdk/trunk.
26. Testing The Fix
The Flex SDK team has an automation tool called
“Mustella” which they use to test the SDK.
To run the check-in tests from command-line, change
to the version you are working on and run:
ant checkintests
29. OpenSource.Adobe.com
Be sure to spend some time looking around this site. It
has almost all the information you could ever want
about the Flex SDK... including:
Detailed Setup Instructions
Coding Conventions
In-Depth Specs and Whitepapers
30. Bug Quashes are fast paced, high energy events. With
food and drinks, good music, lots of code and breaking
things. Good times to be had.
Created by Nate Beck, Marty Mickelson & Mike
Johnson
The next BugQuash event is being planned right now,
the date is currently being determined.
http://www.bugquash.com
31. Show off with the BugQuash badges
Automatically updated
Available at http://www.bugquash.com
32. Thanks!
Now get out there, and do some good!
These slides and this recording will be posted on my
blog at:
http://blog.natebeck.net
Questions?