themightychris
23 Oct 2012, 8:24 PM
I generated an ExtJS app with CMD v3.0.0.201 and found that by default a production build didn't strip <debug> directives.
I want the debug=false option to be part of the project config so they are always stripped, is there a clean way to do this in sencha.cfg? Shouldn't it be the default behavior to strip <debug> code in production builds?
I thought this might do it in .sencha/app/build-impl.xml:
<target name="-page">
<!-- initialize the build.dir parameter if it hasn't been already -->
<local name="build.dir"/>
<property name="build.dir" location="${workspace.build.dir}"/>
<!-- compile the page -->
<x-sencha-command>
compile
-debug=false
page
+yui
-in=index.html
-out=${build.dir}/index.html
</x-sencha-command>
</target>
and it works for class files but it doesn't seem to effect app.js
I want the debug=false option to be part of the project config so they are always stripped, is there a clean way to do this in sencha.cfg? Shouldn't it be the default behavior to strip <debug> code in production builds?
I thought this might do it in .sencha/app/build-impl.xml:
<target name="-page">
<!-- initialize the build.dir parameter if it hasn't been already -->
<local name="build.dir"/>
<property name="build.dir" location="${workspace.build.dir}"/>
<!-- compile the page -->
<x-sencha-command>
compile
-debug=false
page
+yui
-in=index.html
-out=${build.dir}/index.html
</x-sencha-command>
</target>
and it works for class files but it doesn't seem to effect app.js