Likely mtasc writes the output to stderr instead of stdout. You can redirect stderr to stdout using 2>&1, so the command would be:
complieResult=$( mtasc 2>&1 -cp "$TM_MX_CLASSES" … )
This should get you the error output nicely formatted for HTML:
mtasc -cp "$TM_MX_CLASSES" -cp "$TM_CLASS_PATH" -cp "$TM_CLASS_PATH/FP8" -cp "$PROJECT_DIR/src" -cp "$PROJECT_DIR/ classes" -version $flashVersion -trace $traceOption -frame 10 -mx - out "$TM_SWF_OUTPUT" -swf "$TM_SWF_INPUT" "Main.as" 2>&1 | grep characters | grep -v warning | perl -pi -e 's/^(.+?):(.+?): characters? (\d+?)(?:-\d+)? : (.*)$/<a href="txmt:\/\/open? file=$TM_PROJECT_DIRECTORY$1&line=$2&column=$3">$1:$2: $4</a>/g' ___________________ Ben Jackson Diretor de Desenvolvimento
+55 (21) 2256-1022 ben@incomumdesign.com http://www.incomumdesign.com
On 23/01/2006, at 14:26, Benjamin Jackson wrote:
mtasc -cp "$TM_MX_CLASSES" -cp "$TM_CLASS_PATH" -cp "$TM_CLASS_PATH/FP8" -cp "$PROJECT_DIR/src" -cp "$PROJECT_DIR/ classes" -version $flashVersion -trace $traceOption -frame 10 -mx - out "$TM_SWF_OUTPUT" -swf "$TM_SWF_INPUT" "Main.as" 2>&1 | grep characters | grep -v warning | perl -pi -e 's/^(.+?):(.+?): characters? (\d+?)(?:-\d+)? : (.*)$/<a href="txmt:\/\/open?file= $TM_PROJECT_DIRECTORY$1&line=$2&column=$3">$1:$2: $4</a>/g'
It's funny how, the nicer one tries to make the output, the more unreadable the commands to make it so, seem to become :-p.
-- Sune.