<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">So, <div><br></div><div>I've just installed the AS3 bundle from the repository in TextMate and thought I'd share the steps I had to go through in order to make it work, partially so I have a document explaining what I had to do (if I need to do it again) and to help others who might be stuck.  </div><div><br></div><div><div>Message for Simon Gregory: This was the bundle I downloaded from the repository so it's possible that the svn version is b0rked... :(</div><div><br></div></div><div>I have an up to date version of TM on Leopard, and I used the "Get AS3 Bundle.sh" script that I downloaded a short while ago.  Unfortunately I couldn't find the site where it came from but it just appears to grab the latest version from the repository by svn so it can't do that much.</div><div><br></div><div>First, I got the wonderful error dialog:</div><div><br></div><div><blockquote type="cite" class=""><font class="Apple-style-span" color="#000000">The “ActionScript 3” bundle located in ~/Library/Application Support/TextMate/Bundles could not be loaded and will be skipped. The contained info.plist appears to be corrupt or missing.</font></blockquote></div><div><br></div><div>What's going on here?  No idea.  So I looked at the plist file in question and found what looked like a half failed diff at the bottom:</div><div><br></div><div><div><<<<<<< .mine</div><div>... some txt</div><div><div>=======</div><div>... other text</div><div><div>>>>>>>> .r10513</div><div><br></div><div>This is present in a bunch of files, I have so far found it in build_with_fcsh.sh and asd.rb.  Anywho, I took that out of the plist file, probably breaking it slightly but at least TM now loads the AS3 bundle.</div></div></div></div><div><br></div><div>Next I created a new, blank AS3 project.  Make a more or less empty class and "Build with FCSH".  Nothing, no output, no error, no feedback, nothing.  Build with MXMLC, a window pops up telling me there's 0 errors and a successful build, but no .swf file was produced in the deploy/ folder.  Try the "Build (custom)" option, it tells me the script is not executable.  Joy.  So I run the supplied compile.sh script manually by opening the script and pressing Apple-R to run it.  TM alerts me that the script is not executable, so I make it so.  OK, so now it runs.</div><div><br></div><div>However, still nothing coming out of mxmlc, still 0 errors.  What happens when I run mxmlc on it's own?  I get this wonderful error:</div><div><br></div><div><div>-bash: ./mxmlc: /bin/sh^M: bad interpreter: No such file or directory</div><div><br></div></div><div>Joy.  That error is familiar, usually found when running a binary built for a different architecture, but that wasn't the problem.  mxmlc turns out to be a shell script that runs slightly different commands for windows and unix.  Turns out that the default file supplied by Adobe is also in DOS encoding (funny line endings).  So, open the file in vim and type:</div><div><br></div><div># vim ./mxmlc</div><div>:set ff=unix</div><div>:wq</div><div><br></div><div>And the script now runs mxmlc properly.  I also had to chmod a+x in Flex/bin/* as well.  </div><div><br></div><div>OK, so building in mxmlc now works but I know that it's slow and I'd rather use fcsh to do my compiles.  So I try building with fcsh and get even less reponse, no progress bar, no iTerm window, nada.  OK, stay calm...</div><div><br></div><div>So I check the encoding of the fcsh script supplied by Flex, it too was in DOS format so I converted it back to Unix.  That script now fires up the fcsh compiler so that part worked.  Next, why was the build command silently failing?  Open up the Bundle Editor and edit the "Build (fcsh)" command to show output as HTML.  This revealed a syntax error in the build_with_fcsh.sh script.  Find the script, open it in vim and I found the same sort of failed diffs as I found in the plist file.  </div><div><br></div><div>This time I just copied the r10513 file over the existing one:</div><div><br></div><div># cd "/Users/gaby/Library/Application Support/TextMate/Bundles/ActionScript 3.tmbundle/Support/bin/"</div><div># cp build_with_fcsh.sh.r10513 build_with_fcsh.sh</div><div><br></div><div>Now the script works, fcsh works, mxmlc works and I have finally got a .swf file being output into the deploy folder.  Sorry for the length of this rant but my hope is that if anybody else is fighting with AS3 under TextMate, hopefully this might shed some light on problems they're having.</div><div><br></div><div>Gaby</div><div><br><div apple-content-edited="true"> <span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; -webkit-text-decorations-in-effect: none; text-indent: 0px; -webkit-text-size-adjust: auto; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; -webkit-text-decorations-in-effect: none; text-indent: 0px; -webkit-text-size-adjust: auto; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px; "><span class="Apple-style-span" style="border-collapse: separate; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; -webkit-text-decorations-in-effect: none; text-indent: 0px; -webkit-text-size-adjust: auto; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px; "><span class="Apple-style-span" style="border-collapse: separate; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; -webkit-text-decorations-in-effect: none; text-indent: 0px; -webkit-text-size-adjust: auto; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px; "><span class="Apple-style-span" style="border-collapse: separate; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; -webkit-text-decorations-in-effect: none; text-indent: 0px; -webkit-text-size-adjust: auto; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px; "><div>--</div><div>Being drunk is feeling sophisticated without being able to say it.</div></span></span><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><a href="http://www.playr.co.uk/">http://www.playr.co.uk/</a></div></span></span></div></span></div></span> </div><br></div></body></html>