title: Ant script: Have <exec> tag dump out entire command line
body: <p>I have an ant build script with a fairly complex <code>&lt;exec&gt;</code> command with lots of <code>&lt;arg&gt;</code> tags that I'm trying to troubleshoot. I was wondering if it is possible to view the entire command line after ant has constructed it; either in the eclipse debugger or maybe by dumping it to a file.</p>
  
  <p>Here's what I'm dealing with:</p>
  
  <pre><code>&lt;exec executable='"@{sdk}/bin/mxmlc.exe"' failonerror="true" &gt;
                  &lt;arg line='-load-config "@{sdk}/frameworks/flex-config.xml"'/&gt;
  
                  &lt;!-- Flex Build Path --&gt;
                  &lt;!-- Source path --&gt;
                  &lt;!-- Main source folder: --&gt;
                  &lt;arg line='-compiler.source-path "@{project-dir}/src"'/&gt;
                  &lt;!-- Additional source folders outside of the main source folder: --&gt;
                  &lt;arg line='-compiler.source-path "@{project-dir}/inc/swf"'/&gt;
                  &lt;arg line='-compiler.source-path "@{project-dir}/inc/images"'/&gt;
  
                  &lt;!-- Output folder: --&gt;
                  &lt;arg line='-output "@{output}"'/&gt;
  
                  &lt;!-- Library path --&gt;
                  &lt;!-- Build path libraries: --&gt;
                  &lt;arg line='-compiler.library-path "@{libs}"'/&gt;
                  &lt;arg line='-compiler.library-path "@{sdk}/frameworks/libs"'/&gt;
                  &lt;arg line='-compiler.library-path "@{sdk}/frameworks/locale/en_US"'/&gt;
                  &lt;arg line='-compiler.library-path "${dcradswcs.flex.path}/libs"'/&gt;
                  &lt;arg line='-compiler.library-path "${dcradswcs.flex.path}/locale"'/&gt;
                  &lt;arg line='-compiler.library-path "${fiberswcs.flex.path}/libs"'/&gt;
                  &lt;arg line='-compiler.library-path "${fiberswcs.flex.path}/locale"'/&gt;
                  &lt;arg line='-compiler.library-path "${flexunitframework.flex.path}/flexunitframework/libs/version4libs/Common"'/&gt;
                  &lt;arg line='-compiler.library-path "${flexunitframework.flex.path}/flexunitframework/libs/version4libs/FlexProject"'/&gt;
                  &lt;arg line='-compiler.library-path "${flexunitframework.flex.path}/flexunitframework/locale/version4locale"'/&gt;
                  &lt;arg line='-compiler.library-path "${flexunitframework.flex.path}/flexunitframework/libs"'/&gt;
                  &lt;!-- &lt;arg line='-compiler.library-path "C:/rms-it-apps/adobe/fb4/plugins/com.adobe.flexbuilder.dcrad_4.0.1.277662/dcradSwcs/4.0/libs"'/&gt;
                  &lt;arg line='-compiler.library-path "C:/rms-it-apps/adobe/fb4/plugins/com.adobe.flexbuilder.dcrad_4.0.1.277662/dcradSwcs/4.0/locale"'/&gt;
                  &lt;arg line='-compiler.library-path "C:/rms-it-apps/adobe/fb4/plugins/com.adobe.flexbuilder.dcrad_4.0.1.277662/fiberSwcs/4.0/libs"'/&gt;
                  &lt;arg line='-compiler.library-path "C:/rms-it-apps/adobe/fb4/plugins/com.adobe.flexbuilder.dcrad_4.0.1.277662/fiberSwcs/4.0/locale"'/&gt;
                  &lt;arg line='-compiler.library-path "C:/rms-it-apps/adobe/fb4/plugins/com.adobe.flexbuilder.flexunit_4.0.1.277662/flexunitframework/libs/version4libs/Common"'/&gt;
                  &lt;arg line='-compiler.library-path "C:/rms-it-apps/adobe/fb4/plugins/com.adobe.flexbuilder.flexunit_4.0.1.277662/flexunitframework/libs/version4libs/FlexProject"'/&gt;
                  &lt;arg line='-compiler.library-path "C:/rms-it-apps/adobe/fb4/plugins/com.adobe.flexbuilder.flexunit_4.0.1.277662/flexunitframework/locale/version4locale"'/&gt;
                  &lt;arg line='-compiler.library-path "C:/rms-it-apps/adobe/fb4/plugins/com.adobe.flexbuilder.flexunit_4.0.1.277662/flexunitframework/libs"'/&gt; --&gt;
  
                  &lt;!-- Runtime shared libraries. Order matters. --&gt;
                  &lt;!-- Load framework libraries first --&gt;
                  &lt;arg line='-runtime-shared-library-path="@{sdk}/frameworks/libs/textLayout.swc","textLayout_1.1.0.604.swz",,"textLayout_1.1.0.604.swf"'/&gt;
                  &lt;arg line='-runtime-shared-library-path="@{sdk}/frameworks/libs/osmf.swc","osmf_flex.4.0.0.13495.swz",,"osmf_flex.4.0.0.13495.swf"'/&gt;
                  &lt;arg line='-runtime-shared-library-path="@{sdk}/frameworks/libs/framework.swc","framework_4.1.0.16076.swz",,"framework_4.1.0.16076.swf"'/&gt;
                  &lt;arg line='-runtime-shared-library-path="@{sdk}/frameworks/libs/spark.swc","spark_4.1.0.16076.swz",,"spark_4.1.0.16076.swf"'/&gt;
                  &lt;arg line='-runtime-shared-library-path="@{sdk}/frameworks/libs/sparkskins.swc","sparkskins_4.1.0.16076.swz",,"sparkskins_4.1.0.16076.swf"'/&gt;
                  &lt;arg line='-runtime-shared-library-path="@{sdk}/frameworks/libs/rpc.swc","rpc_4.1.0.16076.swz",,"rpc_4.1.0.16076.swf"'/&gt;
                  &lt;arg line='-runtime-shared-library-path="@{sdk}/frameworks/libs/datavisualization.swc","datavisualization_4.1.0.16076.swz",,"datavisualization_4.1.0.16076.swf"'/&gt;
  
                  &lt;!-- Load after framework libraries --&gt;
                  &lt;!-- Note: do not put spaces between comma delimited values --&gt;
                  &lt;arg line='${rsl.applicationSettings}'/&gt;
                  &lt;arg line='${rsl.authorization}'/&gt;
                  &lt;arg line='${rsl.autofill}'/&gt;
                  &lt;arg line='${rsl.customComponents}'/&gt;
                  &lt;arg line='${rsl.navigation}'/&gt;
                  &lt;arg line='${rsl.lookup}'/&gt;
  
                  &lt;!-- Libraries needed for QTP --&gt;
                  &lt;arg line="${qtp.arg1}"/&gt; 
                  &lt;arg line="${qtp.arg2}"/&gt;
                  &lt;arg line="${qtp.arg3}"/&gt;
                  &lt;arg line="${qtp.arg4}"/&gt;
                  &lt;arg line="${qtp.arg5}"/&gt;
  
                  &lt;arg line="-verify-digests=false"/&gt;
  
                  &lt;!-- Flex Compiler --&gt;
                  &lt;!-- Compiler options --&gt;
                  &lt;arg line="-compiler.accessible=true"/&gt;
                  &lt;arg line="-compiler.strict=true"/&gt;
                  &lt;arg line="-warnings=true" /&gt;
  
                  &lt;!-- Additional compiler arguments: --&gt;
                  &lt;arg line='-theme=@{sdk}/frameworks/themes/Halo/halo.swc -services "@{services-config}" -locale en_US'/&gt;
  
                  &lt;!-- Flex Server --&gt;        
                  &lt;!-- Server location --&gt;
                  &lt;!-- Context root: --&gt;
                  &lt;arg line="-compiler.context-root=@{context-root}"/&gt;
  
                  &lt;!-- Miscellaneous --&gt;
                  &lt;arg line="-compiler.incremental=true"/&gt;
                  &lt;arg line="-compiler.keep-generated-actionscript=false"/&gt;
                  &lt;arg line="-compiler.verbose-stacktraces=true"/&gt;                
                  &lt;arg line="-show-unused-type-selector-warnings=false"/&gt;         
                  &lt;arg line="-optimize=true" /&gt;       
                  &lt;arg line="-debug=@{debug}" /&gt;                              
                  &lt;arg line='"@{mxml}"'/&gt;
              &lt;/exec&gt;
  </code></pre>
  
  <p>This is the error I'm getting:</p>
  
  <pre><code>BUILD FAILED
  C:\dev\workspace\rmsitepi2\build.raytheon.suite.tomcat.xml:50: The following error occurred while executing this line:
  C:\dev\workspace\rmsitepi2\build.raytheon.flex.xml:33: The following error occurred while executing this line:
  C:\dev\workspace\rmsitepi2\build.raytheon.flex.xml:159: exec returned: 1
  </code></pre>