Quickly generating AsDoc
For ease of use i have a small batch file to generate the documentation for my ActionScript projects. It’s definitely nothing special, but if you struggle with the asdoc syntax and you just want a quick solution, here it is:
@echo off
set asdoc_bin="E:\projects\flex_sdk_3\bin\asdoc.exe"
set aswing_path="E:\projects\aswing\trunk\AsWing\bin"
%asdoc_bin% -doc-sources org\dirty_motherfucker\. -main-title "My ActionScript Project" -output "doc" -compiler.library-path %aswing_path%
pause
It also points asdoc to the bin directory of AsWing, where it will find the .swc files needed so it can fully understand each part of the sources in my namespace.
If you use several libraries, you will have to supply the library paths as well.
Now, let’s say you don’t have every library available as .swc and you also don’t feel like compiling one. Then you’d use -compiler.source-path. Here is an example of a project that uses more libraries.
@echo off
set asdoc_bin="E:\projects\flex_sdk_3\bin\asdoc.exe"
set aswing_path="E:\projects\aswing\trunk\AsWing\bin"
set aswingkit_path="E:\projects\AsWingKit\src"
set puremvc_path="E:\projects\PureMVC\src"
set tweenlite_path="E:\projects\TweenFilterLiteAS3"
%asdoc_bin% -doc-sources src\org\dirty_motherfucker -main-title "Content Delivery Framework" -output "doc" -compiler.library-path %aswing_path% -compiler.source-path %puremvc_path% %aswingkit_path% %tweenlite_path% src\ -warnings
pause
Also, note in this second example that i include src\ in the source paths. I only generate the documentation for the files in my namespace, but those use source file which reside in the same project directory, thus you should include the whole source directory to make sure everything runs smoothly.