I have a Maven based web application which uses typical Maven directory structure. I have created an Ext JS 4.1.1a application to ${basedir}/src/main/webapp directory using Sencha Cmd

For development purposes I use maven-jetty-plugin and generated index.html which uses Ext.Loader to load scripts dynamically. There's a bug http://www.sencha.com/forum/showthre...l=1#post897523 which is fortunately easy to fix.

During creating a war-package, on 'prepare-package' phase, I run 'secnha ant build' by using exec-maven-plugin to make a production build of ExtJS 4 app. I don't want to pollute ${basedir}/src/main/webapp directory so I have changed workspace.build.dir(in ${basedir}/src/main/webapp/.sencha/workspace/sencha.cfg) to ${basedir}/target. This works relatively fine. There are some bugs which are reported on the forum. For example some image urls generated are absolute not relative.

After succesful build, build directory contains index.html, all-classes.js and ext and resources directories. I use ant copy tasks to copy files back to ${basedir}/src/main/webapp directory so that they are included in war package.
<target name="-after-build">
    <copy file="${workspace.build.dir}/all-classes.js" tofile="all-classes.js"/>
    <copy file="${workspace.build.dir}/index.html" tofile="index.jsp"/>

However I am not sure what to do with the ext and resources directories. I just cannot copy them to ${basedir}/src/main/webapp because it already has those directories generated by Sencha Cmd and are used during development. 'sencha ant build' generated ext and resources directories are not identical with directories generated initially by 'sencha generate app'.

Is there anyone who has same kind of setup? How do you handle the situation?