On my team at work, we're just starting to switch over to IntelliJ IDEA (13.1.1, Build #IU-135.480) from FlashBuilder for Flex development, and are having some trouble understanding the make/compile model. I'm hoping someone here can help us out. We've got a set of IntelliJ modules that look roughly like this:
main-module
flex-app-1.swf
flex-app-2.swf
flex-app-3.swf
library-module-1
library1.swc
library-module-2
library2.swc
library-module-3
library3.swc
library-module-4
library4.swc
The dependencies look like this:
flex-app-1.swf ----> library1.swc -----> library2.swc -----> library4.swc
`---> library3.swc ---'
And the same for each of the other flex apps (let's say for now, anyway). All dependecies are of type "merged".
As far as I can tell, there are three make/compile variants:
- Make Project seems to unconditionally rebuild all of the IntelliJ modules
- Make Module 'foo' rebuilds 'foo' and everything it depends on. So in the case of Make Module 'main-module', it'll uncondtionally rebuild the library modules and all three SWF's in main-module
- Compile 'foo' compiles the IntelliJ module containing the file 'foo' IF anything in it has changed. Or possibly only if 'foo' has changed. I'm not really clear on that. And if 'foo' is one of the SWF mxml files, it appears to only compile that particular SWF, not all three of them. I think.
So, some questions about all this:
- Have I got it right?
- Suppose I change a file in library2.swc and ONLY want to compile library2.swc, library1.swc, and flex-app-1.swf, since I'm going to run and monkey-test flex-app-1. Is there an easy way to do that? Right now, it feels like I have to select flex-app-1.mxml in the Project window, hit "Compile" from there, and then hit Run or Debug. That's kind of a pain in the neck. I know that I can add "Make" to my launch config, but that seems to do either "Make Project" or "Make Module", which does all IntelliJ modules and takes longer (not as long as it did in FlashBuilder, mind you, and it doesn't run out of memory and crash and burn every 4 or 5 times like it did in Flash Builder, but it still takes longer. now that I've got the moon, I want the stars!)
- Could we get what I'm looking for if we changed from "Merged" dependencies to something else? What's the downside to changing?
Note: our project structure is actually much deeper and more complex than this, but the same ideas should hold true.
Thanks in advance!