Android sencha构建本机:构建脚本
我正在为android开发一个使用sencha touch和phonegap定位的移动应用程序。我需要创建用于构建sencha touch应用程序和创建apk文件的ant构建脚本。该apk文件应移动到某个位置,以便将应用程序分发给团队。我无法增强build.xml文件来执行sencha touch应用程序文件夹中的相同操作 如何创建将创建.apk文件并移动到某个位置以分发应用程序的构建Android sencha构建本机:构建脚本,android,cordova,ant,sencha-touch-2.2,Android,Cordova,Ant,Sencha Touch 2.2,我正在为android开发一个使用sencha touch和phonegap定位的移动应用程序。我需要创建用于构建sencha touch应用程序和创建apk文件的ant构建脚本。该apk文件应移动到某个位置,以便将应用程序分发给团队。我无法增强build.xml文件来执行sencha touch应用程序文件夹中的相同操作 如何创建将创建.apk文件并移动到某个位置以分发应用程序的构建 --Sridhar您可以使用ANT创建android(apk)构建。build.xml应该包含下面命令的任务
--Sridhar您可以使用ANT创建android(apk)构建。build.xml应该包含下面命令的任务
您可以简单地使用“AntBuild”来执行上述脚本。
确保已正确安装ant和cordova
<target name="production">
<exec executable="cmd" dir="app">
<arg line="/c 'sencha app build production'"/>
</exec>
</target>
<target name="build" depends="production">
<delete dir="${cordova-path}/www"/>
<copy todir="${cordova-path}/www">
<fileset dir="app/build/my_app/production" />
</copy>
<copy file="${cordova-path}/config.xml" todir="${cordova-path}/www" overwrite="true" />
<exec dir="${cordova-path}" executable="cmd">
<arg line="/c 'cordova build'"/>
</exec>
</target>
<target name="deploy" depends="build">
<copy file="${cordova-path}/platforms/android/bin/app-debug.apk" todir="." overwrite="true" />
</target>