A TextMate bundle to help maintain and create ActionScript 3 TextMate Bundles.
The scripts that do the work parse ASDoc generated html documentation. Admittedly this makes them fragile, but it does mean that private source code can be targeted where documentation is available. It also made the parsing easier.
Be aware that as REXML sucks badly on the speed front you'll be seeing the beach ball for quite a while before the task finishes. The only option is to hang in there, or you could spend the time to refactor the scripts to use nokogiri.
To install via Git:
cd ~/"Library/Application Support/TextMate/Bundles/"
git clone git://github.com/simongregory/actionscript3-bundle-generator.tmbundle.git
osascript -e 'tell app "TextMate" to reload bundles'
Source can be viewed and forked via GitHub
To update the ActionScript 3.tmbundle language grammar, help dictionary, completions, and method completion (shortcut's) lists run the 'Update ActionScript 3 Bundle' command from the bundle menu.
The following values are hardcoded into bin/as3_bundle_update
and may need to
be changed to suit your setup:
BUNDLE_PATH = "/Users/#{user}/Library/Application Support/TextMate/Bundles/ActionScript 3.tmbundle"
FLASH_PATH = '/Library/Application Support/Adobe/Help/en_US/AS3LCR/Flash_10.0/all-classes.html'
FLEX_PATH = '/Developer/SDKs/flex_sdk_4.0.0/asdoc-output/all-classes.html'
TEMP_OUTPUT = "/Users/#{user}/Desktop/as3_bundle_generator_temp"
To create a bundle for a ActionScript framework you need to generate adocs for it
then open them as a project. Select the 'all-classes.html' file in the project
draw then run the New Bundle
command from the menu. You should then find the
a bundle tailored for the framework on your Desktop. Note Although this is
possible it's not particularly useful in practice because of restrictions
TextMate has with language grammar inheritance. Fingers crossed that TM2 will be
released and there'll be a better way to mix-in frameworks.
For Bundle conventions please follow the TextMate conventions.
Or you can try dropping me an email via github.
If not otherwise specified (see below), files in this project fall under the following license:
Copyright 2007-2010 Simon Gregory
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
An exception is made for files in readable text which contain their own license information, or files where an accompanying file exists (in the same directory) with a “-license” suffix added to the base-name name of the original file, and an extension of txt, html, or similar.