Sench Cmd4 打包apk失败

xyj052 2014-10-07 11:04:32
用sencha Cmd4把刚刚用命令生成出来的代码打包成apk失败,请各位大神看看,这个是为什么啊!
E:\MyApp>sencha app build native
Sencha Cmd v4.0.4.84
[INF]
[INF] init-plugin:
[INF]
[INF] cmd-root-plugin.init-properties:
[INF]
[INF] init-properties:
[INF]
[INF] init-sencha-command:
[INF]
[INF] init:
[INF]
[INF] app-build-impl:
[INF]
[INF] -before-init-local:
[INF]
[INF] -init-local:
[INF]
[INF] -after-init-local:
[INF]
[INF] init-local:
[INF]
[INF] find-cmd-in-path:
[INF]
[INF] find-cmd-in-environment:
[INF]
[INF] find-cmd-in-shell:
[INF]
[INF] init-cmd:
[INF] [echo] Using Sencha Cmd from D:\SenchaTouch4\Sencha\Cmd\4.0.4.84 for
E:\MyApp\build.xml
[INF]
[INF] -before-init:
[INF]
[INF] -init:
[INF] Initializing Sencha Cmd ant environment
[INF] Adding antlib taskdef for com/sencha/command/compass/ant/antlib.xml
[INF]
[INF] -after-init:
[INF]
[INF] -before-init-defaults:
[INF]
[INF] -init-defaults:
[INF]
[INF] -after-init-defaults:
[INF]
[INF] -init-compiler:
[INF]
[INF] init:
[INF]
[INF] -before-build:
[INF]
[INF] refresh:
[INF]
[INF] -before-refresh:
[INF]
[INF] -init:
[INF]
[INF] -init-compiler:
[INF]
[INF] -detect-app-build-properties:
[INF] Loading app json manifest...
[INF] Loading classpath entry E:\MyApp\touch\src
[INF] Loading classpath entry E:\MyApp\app.js
[INF] Loading classpath entry E:\MyApp\app
[INF] Loading classpath entry E:\MyApp\build\temp\native\Myapp\sencha-compiler\a
pp
[INF] Loading classpath entry E:\MyApp\build\temp\native\Myapp\sencha-compiler\a
pp
[INF] Concatenating output to file E:\MyApp/build/temp/native/Myapp/sencha-compi
ler/cmd-packages.js
[INF] Adding external reference : @full-page => @overrides
[INF] Loading classpath entry E:\MyApp\build\temp\native\Myapp\sencha-compiler\c
md-packages.js
[INF] Adding external reference : Ext.util.Observable => E:\MyApp/build/temp/nat
ive/Myapp/sencha-compiler/cmd-packages.js
[INF]
[INF] -refresh-app:
[INF] Appending concatenated output to file E:\MyApp/bootstrap.js
[INF] Appending concatenated output to file E:\MyApp/bootstrap.js
[INF] Appending concatenated output to file E:\MyApp/bootstrap.js
[INF] Appending concatenated output to file E:\MyApp/bootstrap.js
[INF] Appending concatenated output to file E:\MyApp/bootstrap.js
[INF] Appending content to E:\MyApp/bootstrap.json
[INF]
[INF] -refresh:
[INF]
[INF] -after-refresh:
[INF]
[INF] resolve:
[INF]
[INF] js:
[INF]
[INF] -before-js:
[INF]
[INF] -init:
[INF]
[INF] -init-compiler:
[INF]
[INF] -detect-app-build-properties:
[INF]
[INF] -compile-js:
[INF] Compressing data with YuiJavascriptCompressor
[INF] Concatenating output to file E:\MyApp/build/native/Myapp/app.js
[INF]
[INF] -js:
[INF]
[INF] -after-js:
[INF]
[INF] resources:
[INF]
[INF] -before-resources:
[INF]
[INF] -before-inherit-resources:
[INF]
[INF] -before-copy-resources:
[INF]
[INF] -init:
[INF]
[INF] -init-compiler:
[INF]
[INF] -resources:
[INF] merging resources into E:\MyApp\build\native\Myapp\resources
[INF] merged 0 resources into E:\MyApp\build\native\Myapp\resources
[INF] merging resources into E:\MyApp\build\native\Myapp
[INF] merged 0 resources into E:\MyApp\build\native\Myapp
[INF]
[INF] -after-copy-resources:
[INF]
[INF] -after-inherit-resources:
[INF]
[INF] -after-resources:
[INF]
[INF] sass:
[INF]
[INF] -before-sass:
[INF]
[INF] -compass-compile-theme-package:
[INF]
[INF] -compass-compile-theme-folders:
[INF]
[INF] -compass-compile-sass-dir:
[INF] executing compass using system installed ruby runtime
identical ../css/app.css
[INF]
[INF] -compass-compile:
[INF]
[INF] -sass:
[INF]
[INF] -after-sass:
[INF]
[INF] slice:
[INF]
[INF] -before-slice:
[INF]
[INF] -slice-images:
[INF]
[INF] -slice:
[INF]
[INF] -after-slice:
[INF]
[INF] page:
[INF]
[INF] -before-page:
[INF]
[INF] -init:
[INF]
[INF] -init-compiler:
[INF]
[INF] -copy-app-resources:
[INF] Copying page resources to E:\MyApp\build\native\Myapp
[INF] copying E:\MyApp\resources\css\app.css to E:\MyApp\build\native\Myapp\reso
urces\css\app.css
[INF]
[INF] -generate-deltas:
[INF]
[INF] -detect-app-build-properties:
[INF]
[INF] -build-standalone-json-manifest:
[INF] Writing content to E:\MyApp/build/native/Myapp/app.json
[INF]
[INF] -build-output-page:
[INF]
[INF] -build-output-microload-page:
[INF] Writing content to E:\MyApp/build/native/Myapp/microloader.js
[INF] Appending content to E:\MyApp/build/native/Myapp/microloader.js
[INF] Building output markup to E:\MyApp/build/native/Myapp/index.html
[INF] [delete] Deleting: E:\MyApp\build\native\Myapp\microloader.js
[INF]
[INF] -generate-cache-manifest:
[INF]
[INF] -page:
[INF]
[INF] -after-page:
[INF]
[INF] native-package:
[INF]
[INF] -before-native-package:
[INF]
[INF] -native-package-mobile:
[INF] [echo] Building all specified mobile packager configs.
[INF] [echo]
[INF] [echo] Processing Mobile Packager config file
[INF] [echo] config: E:\MyApp/packager.json
[INF] [echo] inputPath: E:\MyApp/build/native/Myapp
[INF] [echo] outputPath: E:\MyApp/build/native-package-mobile/Myapp
/packager.json
[INF] [echo] Running mobile packager action build on file E:\MyApp/packager
.temp.json
[ERR]
?????????????¨???·????
""E:/AndroidSDK/sdk/tools\tools\android" create project --target android-19 --na
me Myapp --activity STActivity --path "E:\MyApp/build/native-package-mobile/Myap
p/packager.json\/" --package com.Myapp"
Failed to create android project
Failed to package application

[ERR]
[ERR] BUILD FAILED
[ERR] com.sencha.exceptions.ExProcess: stbuild exited with non-zero code : 6
[ERR] at org.apache.tools.ant.Target.performTasks(Targ
[ERR] et.java:413)
[ERR]
[ERR] Total time: 8 seconds
[ERR] The following error occurred while executing this line:
E:\MyApp\.sencha\app\build-impl.xml:422: The following error occurred while exec
uting this line:
E:\MyApp\.sencha\app\packager-impl.xml:112: The following error occurred while e
xecuting this line:
E:\MyApp\.sencha\app\packager-impl.xml:114: The following error occurred while e
xecuting this line:
E:\MyApp\.sencha\app\packager-impl.xml:98: The following error occurred while ex
ecuting this line:
E:\MyApp\.sencha\app\packager-impl.xml:7: com.sencha.exceptions.ExProcess: stbui
ld exited with non-zero code : 6





...全文
290 10 打赏 收藏 转发到动态 举报
写回复
用AI写文章
10 条回复
切换为时间正序
请发表友善的回复…
发表回复
Kifile 2014-10-07
  • 打赏
  • 举报
回复
build-impl.xml和packager-impl.xml,发出来看看呢
xyj052 2014-10-07
  • 打赏
  • 举报
回复
下面这个是配置文件Packager.json
{
	/**
	 * @cfg  applicationName
	 * @required
	 * This is the name of your application, which is displayed on the device when the app is installed. On IOS, this should match
	 * the name of your application in the Apple Provisioning Portal.
	 */
	"applicationName":"Myapp",

	/**
	 * @cfg  applicationId
	 * This is the name namespace for your application. On IOS, this should match the name of your application in the Apple Provisioning Portal.
	 */
	"applicationId":"com.Myapp",

	/**
	 * @cfg  bundleSeedId
	 * A ten character string which stands before aplication ID in Apple Provisioning Portal
	 */
	"bundleSeedId":"KPXFEPZ6EF",

	/**
	 * @cfg  versionString
	 * @required
	 * This is the version of your application.
	 */
	"versionString":"1.0",

	/**
	 * @cfg  versionCode
	 * @required
	 * This is the integer version code of your application, or you can refer to it as a build number. Used only for Android builds.
	 */
	"versionCode":"1",

	/**
	 * @cfg  icon
	 * For iOS, please refer to their documentation about icon sizes:
	 * https://developer.apple.com/library/ios/#documentation/userexperience/conceptual/mobilehig/IconsImages/IconsImages.html
	 *
	 * For Android, please refer to the Google Launcher icons guide:
	 * http://developer.android.com/guide/practices/ui_guidelines/icon_design_launcher.html
	 * iOS uses 57, 72, 114 and 144; Android uses 36, 48 and 72; if you package for Android you can ignore iOS icons and vice verca
	 */
	"icon": {
		"36":"resources/icons/Icon_Android36.png",
		"48":"resources/icons/Icon_Android48.png",
		"57":"resources/icons/Icon.png",
		"72":"resources/icons/Icon~ipad.png",
		"114":"resources/icons/Icon@2x.png",
		"144":"resources/icons/Icon~ipad@2x.png"
	},

	/**
	 * @cfg  inputPath
	 * @required
	 * This is location of your Sencha Touch 2 application, relative to this configuration file.
	 */
	"inputPath": "./",

	/**
	 * @cfg  outputPath
	 * @required
	 * This is where the built application file with be saved. Make sure that output path is not in your input path, you may get into endless recursive copying
	 */
	"outputPath": "../build/",

	/**
	 * @cfg  configuration
	 * @required
	 * This is configuration for your application. `Debug` should always be used unless you are submitting your app to an online
	 * store - in which case `Release` should be specified.
	 */
	"configuration":"Debug",

	/**
	 * @cfg  platform
	 * @required
	 * This is the platform where you will be running your application. Available options are:
	 *  - iOSSimulator
	 *  - iOS
	 *  - Android
	 *  - AndroidEmulator
	 */
	"platform":"Android",

	/**
	 * @cfg  deviceType
	 * @required
	 * This is device type that your application will be running on.
	 *
	 * If you are developing for Android, this is not necessary.
	 *
	 * Available options are:
	 *  - iPhone
	 *  - iPad
	 *  - Universal
	 */
	"deviceType":"Universal",

	/**
	 * @cfg  certificatePath
	 * This is the location of your certificate.
	 * This is required when you are developing for Android or you are developing on Windows.
	 */
	"certificatePath":"license/kzoncj.keystore",

	/**
	 * @cfg  certificateAlias
	 * This is the name of your certificate.
	 *
	 * IF you do not specify this on OSX, we will try and automatically find the certificate for you using the applicationId.
	 *
	 * This can be just a simple matcher. For example, if your certificate name is "iPhone Developer: Robert Dougan (ABCDEFGHIJ)", you
	 * can just put "iPhone Developer".
	 *
	 * When using a certificatePath on Windows, you do not need to specify this.
	 */
	"certificateAlias":"xyj",
	/**
	 * @cfg  certificatePassword
	 * The password which was specified during certificate export
	 */
	"certificatePassword":"123456",
	/**
	 * @cfg  provisionProfile
	 * The path to the provision profile (APP_NAME.mobileprovision) which you can create and then download from Apple's provisioning portal
	 */
	"provisionProfile":"",
	/**
	 * @cfg  notificationConfiguration
	 * Notification configuration for push notifications, can be "debug", "release" or empty if you don't use push notifications in your project.
	 */
	"notificationConfiguration":"",
	/**
	 * @cfg  sdkPath
	 * This is the path to the Android SDK, if you are developing an Android application.
	 */
	"sdkPath":"E:/AndroidSDK/sdk/tools",

	/**
	 * @cfg  androidAPILevel
	 * This is android API level, the version of Android SDK to use, you can read more about it here: http://developer.android.com/guide/appendix/api-levels.html.
	 * Be sure to install corresponding platform API in android SDK manager (android_sdk/tools/android)
	 */
	"androidAPILevel":"19",

        /**
	 * @cfg {Array[String]} permissions
	 * Array of permissions that is used by an application (Android only) 
	 * Full list of permissions for Android application can be found here: http://developer.android.com/reference/android/Manifest.permission.html#ACCESS_CHECKIN_PROPERTIES
	 */
	"permissions":[
            "INTERNET",
            "ACCESS_NETWORK_STATE",
            "CAMERA",
            "VIBRATE",
            "ACCESS_FINE_LOCATION",
            "ACCESS_COARSE_LOCATION",
            "CALL_PHONE"
        ],

	/**
	 * @cfg {Array[String]} orientations
	 * @required
	 * This is orientations that this application can run.
	 */
	"orientations": [
		"portrait",
		"landscapeLeft",
		"landscapeRight",
		"portraitUpsideDown"
	]
}
xyj052 2014-10-07
  • 打赏
  • 举报
回复
好的,我换种其他方法打包试试
Kifile 2014-10-07
  • 打赏
  • 举报
回复
直接用 ant 打包就好了啊,为什么用 Sench Cmd, 都没听说过
Kifile 2014-10-07
  • 打赏
  • 举报
回复
mac 下不能远程操作,
xyj052 2014-10-07
  • 打赏
  • 举报
回复
这个问题,已经查了好几天的资料了,都没找到解决办法,能远程帮我看下吗,sencha touch和sencha cmd都是刚开始用, 能加我下QQ帮我远程看下吗,我的QQ:344397593
Kifile 2014-10-07
  • 打赏
  • 举报
回复
根据你上传的错误显示,错误发生在 E:\MyApp\.sencha\app\build-impl.xml:422: The following error occurred while exec uting this line: E:\MyApp\.sencha\app\packager-impl.xml:112: The following error occurred while e xecuting this line: E:\MyApp\.sencha\app\packager-impl.xml:114: The following error occurred while e xecuting this line: E:\MyApp\.sencha\app\packager-impl.xml:98: The following error occurred while ex ecuting this line: E:\MyApp\.sencha\app\packager-impl.xml:7: com.sencha.exceptions.ExProcess: stbui ld exited with non-zero code : 6 但是我貌似没有看到有什么特别严重的问题,你可以再检查一下
xyj052 2014-10-07
  • 打赏
  • 举报
回复
这个是packager-impl.xml的内容
<project name="packager-impl">
    <macrodef name="x-run-mobile-packager">
        <attribute name="configfile"/>
        <attribute name="action"/>
        <sequential>
            <echo>Running mobile packager action @{action} on file @{configFile}</echo>
            <x-sencha-command dir="${app.dir}" inheritall="true">
                <![CDATA[
                app
                    package
                        @{action}
                            -path=@{configfile}
                ]]>
            </x-sencha-command>
        </sequential>
    </macrodef>
    
    
    <macrodef name="x-run-mobile-packager-config">
        <attribute name="config"/>
        <attribute name="run" default="${args.autorun}"/>
        <sequential>
            <if>
                <not>
                    <available file="@{config}"/>
                </not>
                <then>
                    <!--
                    if the input packager config file for stbuild is
                    not available, then create it
                    -->
                    <echo><![CDATA[
    Creating default mobile packager config file at : 
    @{config}
                    ]]></echo>
                    <x-run-mobile-packager
                        configfile="@{config}"
                        action="generate"/>
                </then>
            </if>

            <local name="local.build.mobile.out.dir"/>
            <local name="local.build.mobile.config.name"/>
            
            <!--
            append the current config file name to the output directory
            for mobile packages.  this allows multiple config outputs to
            be sandboxed by the name of the config file in the mobile
            package output directory.
            -->
            <basename file="@{config}" property="local.build.mobile.config.name"/>
            <property name="local.build.mobile.out.dir" 
                      value="${build.mobile.packager.out.dir}/${local.build.mobile.config.name}"/>

            <!--
            duplicate the config file, so that we can set the 
            input and output properties w/o losing comment blocks
            -->
            <x-set-json-property file="@{config}"
                                 tofile="${build.mobile.packager.temp.file}">
                <property name="inputPath" 
                          value="${build.mobile.packager.in.dir}"/>
                <property name="outputPath" 
                          value="${local.build.mobile.out.dir}"/>
            </x-set-json-property>

<echo><![CDATA[
    Processing Mobile Packager config file
        config: @{config}
        inputPath: ${build.mobile.packager.in.dir}
        outputPath: ${local.build.mobile.out.dir}
]]></echo>

            <local name="mobile.packager.platform"/>
            
            <x-load-properties file="${build.mobile.packager.temp.file}" 
                               prefix="mobile.packager" 
                               required="true"/>

            <if>
                <contains string="${mobile.packager.platform}" substring="iOS"/>
                <then>
                    <copy todir="${build.dir}">
                        <fileset dir="${app.dir}/resources/icons" includes="**/*"/>
                        <fileset dir="${app.dir}/resources/loading" includes="**/*"/>
                    </copy>
                </then>
            </if>

            <local name="build.mobile.action"/>
            <condition property="build.mobile.action" value="run">
                <x-is-true value="@{run}"/>
            </condition>
            <property name="build.mobile.action" value="build"/>

            <x-run-mobile-packager
                configFile="${build.mobile.packager.temp.file}"
                action="${build.mobile.action}"/>
            </sequential>
    </macrodef>
    
    <target name="-native-package-mobile">
        <if>
            <x-is-true value="${args.autorun}"/>
            <then>
                <echo>Running default mobile packager config.</echo>
                <x-run-mobile-packager-config config="${build.mobile.packager.default.file}" 
                                              run="true"/>
            </then>
            <else>
                <echo>Building all specified mobile packager configs.</echo>
                <for param="configfile" list="${build.mobile.packager.file}">
                    <sequential>
                        <x-run-mobile-packager-config config="@{configfile}" run="false"/>
                    </sequential>
                </for>
            </else>
        </if>
    </target>
    
    <target name="-before-native-package"/>
    <target name="-native-package" 
            depends="-native-package-mobile">
    </target>
    <target name="-after-native-package"/>
    
</project>
xyj052 2014-10-07
  • 打赏
  • 举报
回复
接上部分
  <import file="${basedir}/.sencha/app/js-impl.xml"/>
    <target name="js"
            depends="init"
            description="Builds the output javascript file(s)">
        <x-ant-call unless="skip.js">
            <target name="-before-js"/>
            <target name="-js"/>
            <target name="-after-js"/>
        </x-ant-call>
    </target>
        
    <!--
    ===============================================================
    Sass
    uses targets from sass-impl.xml to produce the output css
    files for the application's styling
    ===============================================================
    -->
    <import file="${basedir}/.sencha/app/sass-impl.xml"/>
    <target name="sass" 
            depends="init" 
            description="Builds the Sass files using Compass.">
        <x-ant-call unless="skip.sass">
            <target name="-before-sass"/>
            <target name="-sass"/>
            <target name="-after-sass"/>
        </x-ant-call>
    </target>

    <!--
    ===============================================================
    Resources
    uses targets from resources-impl.xml to copy resources from 
    the application and required packages to the output directory
    ===============================================================
    -->
    <import file="${basedir}/.sencha/app/resources-impl.xml"/>
    <target name="resources" 
            depends="init"
            description="Copy resources to build folder.">
        <x-ant-call unless="skip.resources">
            <target name="-before-resources"/>

            <!-- Legacy targets: -->
            <target name="-before-inherit-resources"/>
            <target name="-before-copy-resources"/>

            <target name="-resources"/>
           
            <!-- Legacy targets: -->
            <target name="-after-copy-resources"/>
            <target name="-after-inherit-resources"/>

            <target name="-after-resources"/>
        </x-ant-call>
    </target>
    
    
    <!--
    ===============================================================
    Slice
    uses targets from slice-impl.xml to extract theme images from
    the application for use with older browsers that don't 
    support modern css features
    ===============================================================
    -->
    <import file="${basedir}/.sencha/app/slice-impl.xml"/>
    <target name="slice" 
            depends="init" 
            description="Slices CSS3 theme to produce non-CSS3 images and sprites.">
        <x-ant-call unless="skip.slice">
            <target name="-before-slice"/>
            <target name="-slice"/>
            <target name="-after-slice"/>
        </x-ant-call>
    </target>

    <!--
    Theme - this is a legacy support target for extjs 4.1 apps. It redirects
    to the "slice" ant target
    -->
    <target name="theme" 
            depends="init" 
            description="Builds the application's theme(s) images using the slicer (Ext JS 4.1 only).">
        <x-ant-call unless="skip.theme">
            <target name="-before-theme"/>
            <target name="slice"/>
            <target name="-after-theme"/>
        </x-ant-call>
    </target>
                
    <!--
    Refresh Theme - uses targets from refresh-impl.xml to rebuild the current
    theme
    -->
    <target name="refresh-theme" 
            depends="init" 
            description="Rebuilds the currently enabled app theme (Ext JS 4.1 only).">
        <x-ant-call unless="skip.theme">
            <target name="-before-refresh-theme"/>
            <target name="-refresh-theme"/>
            <target name="-after-refresh-theme"/>
        </x-ant-call>
    </target>

    <!--
    ===============================================================
    Refresh
    uses targets from refresh-impl.xml to generate bootstrapping
    information for the application
    ===============================================================
    -->
    <import file="${basedir}/.sencha/app/refresh-impl.xml"/>
    <target name="refresh"
            depends="init"
            description="Refreshes the application bootstrap data.">
        <x-ant-call unless="skip.refresh">
            <target name="-before-refresh"/>
            <target name="-refresh"/>
            <target name="-after-refresh"/>
        </x-ant-call>
    </target>

    <!--
    ===============================================================
    Page
    uses targets from page-impl.xml to generate the output markup
    file and associated microloader / app manifest
    ===============================================================
    -->
    <import file="${basedir}/.sencha/app/page-impl.xml"/>
    <target name="page" 
            depends="init" 
            description="Builds the application's HTML page.">
        <x-ant-call unless="skip.page">
            <target name="-before-page"/>
            <target name="-page"/>
            <target name="-after-page"/>
        </x-ant-call>
    </target>

    <!--
    ===============================================================
    Resolve
    uses targets from resolve-impl.xml to detect dynamic app 
    dependencies using phantomjs
    ===============================================================
    -->
    <import file="${basedir}/.sencha/app/resolve-impl.xml"/>
    <target name="resolve"
            depends="init"
            description="Resolve application dependencies dynamically.">
        <x-ant-call unless="skip.resolve">
            <target name="-before-resolve"/>
            <target name="-resolve"/>
            <target name="-after-resolve"/>
        </x-ant-call>
    </target>

    <!--
    ===============================================================
    Native Package
    uses targets from packager-impl.xml to run native packager
    applications to produce stand-alone installable web apps from
    this built Cmd application
    ===============================================================
    -->
    <import file="${basedir}/.sencha/app/packager-impl.xml"/>
    <target name="native-package"
            depends="init"
            description="Builds native packages of the application">
        <x-ant-call unless="skip.native-package">
            <target name="-before-native-package"/>
            <target name="-native-package"/>
            <target name="-after-native-package"/>
        </x-ant-call>
    </target>

    <!--
    ===============================================================
    Help - properties
    displays all current ant properties
    ===============================================================
    -->
    <target name=".props" depends="init"
            description="Lists all properties defined for the build">
        <echoproperties/>
    </target>

    <!--
    ===============================================================
    Help - docs
    displays the help message
    ===============================================================
    -->
    <target name=".help" depends="init"
            description="Provides help on the build script">
        <x-get-project-targets property="help.message"/>

        <echo><![CDATA[${help.message}
This is the main build script for your application.

The following properties can be used to disable certain steps in the build
process.

 * skip.page        Do not build the HTML page.
 * skip.js          Do not build the output js code file(s)
 * skip.resources   Do not copy resources to the build directory
 * skip.sass        Do not build the SASS.
 * skip.slice       Do not build the theme image slicer.
 * skip.theme       Do not build the theme images.
            
The following properties can be used to modify the build process.
            
 * build.compression.yui                Specify yui compression for the build

 * build.compression.closure            Specify closure compression for the build
            
 * build.compression.uglify             Specify uglify compression for the build
            
 * build.options                        Set general options for the build
                                        (eg: enable a debug build)
 
         To modify any of the previous build specific options, see:
           ${basedir}/.sencha/app/${build.environment}.properties
            
 * build.operations                     Insert commands into the compile command
                                        for the build.
            
 * app.page.name                        Set the input and output page file
                                        for the compile command.
 
 * build.classes.name                   Specify the compiled js file
                                        

For details about how these options affect your build, see

    ${basedir}/.sencha/app/build-impl.xml

These options can be stored in a local.properties file in this folder or in the
local.properties file in the workspace.

Alternatively, these can be supplied on the command line. For example:

    ant -Dskip.sass=1 build

To see all currently defined properties, do this:

    ant .props
        ]]></echo>
    </target>

</project>
xyj052 2014-10-07
  • 打赏
  • 举报
回复
这个是build-impl.xml的内容
<?xml version="1.0" encoding="utf-8"?>
<!--
********************************** DO NOT EDIT **********************************

This file will be replaced during upgrades so DO NOT EDIT this file. If you need to
adjust the process, reading and understanding this file is the first step.

In most cases, the adjustments can be achieved by setting properties or providing one
of the "hooks" in the form of a "-before-" or "-after-" target. Whenever possible, look
for one of these solutions.

Failing that, you can copy whole targets to your build.xml file and it will overrride
the target provided here. Doing that can create problems for upgrading to newer
versions of Cmd so it is not recommended but it will be easier to manage than editing
this file in most cases.
-->
<project name="app-build-impl">
<!--
===============================================================
helper targets for ant integrations with IDE's
(human readable target names)
===============================================================
-->
<target name="-before-build-testing"/>
<target name="-build-testing" depends="testing,build"/>
<target name="-after-build-testing"/>
<target name="build-testing"
depends="-before-build-testing,
-build-testing,
-after-build-testing"/>

<target name="Build - Testing"
description="Create a Testing build of this project"
depends="build-testing"/>

<target name="-before-build-production"/>
<target name="-build-production" depends="production,build"/>
<target name="-after-build-production"/>
<target name="build-production"
depends="-before-build-production,
-build-production,
-after-build-production"/>

<target name="Build - Production"
description="Create a Production build of this project"
depends="build-production"/>

<target name="-before-build-native"/>
<target name="-build-native" depends="native,build"/>
<target name="-after-build-native"/>
<target name="build-native"
depends="-before-build-native,
-build-native,
-after-build-native"/>

<target name="Build - Native"
description="Create a Native build of this project"
depends="build-native"/>

<target name="-before-start-local-webserver"/>
<target name="-start-local-webserver" depends="init">
<x-launch-terminal>
<![CDATA[
${cmd.dir}/sencha fs web -port=${build.web.port} start -map=${build.web.root}
]]>
</x-launch-terminal>
</target>
<target name="-after-start-local-webserver"/>
<target name="start-local-webserver"
depends="-before-start-local-webserver,
-start-local-webserver,
-after-start-local-webserver"/>

<target name="WebServer - Start Local"
description="Starts a local webserver for this project"
depends="start-local-webserver"/>

<target name="-before-compass-watch"/>
<target name="-compass-watch" depends="init">
<x-launch-terminal>
compass watch ${app.sass.dir}
</x-launch-terminal>
</target>
<target name="-after-compass-watch"/>
<target name="compass-watch"
depends="-before-compass-watch,
-compass-watch,
-after-compass-watch"/>

<target name="Compass - Watch"
description="Opens terminal and watches for SASS updates"
depends="compass-watch"/>

<!--
===============================================================
environment setters
===============================================================
-->
<target name="production"
description="Sets the build environment to production.">
<property name="build.environment" value="production"/>
</target>

<target name="testing"
description="Sets the build environment to testing.">
<property name="build.environment" value="testing"/>
</target>

<target name="native"
description="Sets the build environment to native.">
<property name="build.environment" value="native"/>
</target>

<target name="package"
description="Sets the build environment to package.">
<property name="build.environment" value="package"/>
</target>


<!--
===============================================================
Find Cmd
uses targets from find-cmd-impl.xml to detect the current
install of Sencha Cmd
===============================================================
-->
<import file="${basedir}/.sencha/app/find-cmd-impl.xml"/>
<target name="init-cmd"
depends="find-cmd-in-path,
find-cmd-in-environment,
find-cmd-in-shell">
<echo>Using Sencha Cmd from ${cmd.dir} for ${ant.file}</echo>

<!--
load the sencha.jar ant task definitions.

NOTE: the 'loaderref' attribute stores this task def's class loader
on the project by that name, so it will be sharable across sub-projects.
This fixes out-of-memory issues, as well as increases performance.

To supoprt this, it is recommended that any customizations that use
'ant' or 'antcall' tasks set 'inheritrefs=true' on those tasks, in order
to propagate the senchaloader reference to those subprojects.

The sencha 'x-ant-call' task, which extends 'antcall' and defaults
'inheritrefs' to true, may be used in place of antcall in
build process customizations.
-->
<taskdef resource="com/sencha/ant/antlib.xml"
classpath="${cmd.dir}/sencha.jar"
loaderref="senchaloader"/>

<!--
Some operations require sencha.jar in the current java classpath,
so this will extend the java.lang.Thread#contextClassLoader with the
specified java classpath entries
-->
<x-extend-classpath>
<jar path="${cmd.dir}/sencha.jar"/>
</x-extend-classpath>
</target>

<!--
===============================================================
Init
uses targets from init-impl.xml to load Sencha Cmd config
system properties and ant task definitions
===============================================================
-->
<import file="${basedir}/.sencha/app/init-impl.xml"/>
<target name="init"
depends="init-local,
init-cmd,
-before-init,
-init,
-after-init,
-before-init-defaults,
-init-defaults,
-after-init-defaults,
-init-compiler"/>

<!--
===============================================================
Build
this is the starting point for the build process. The 'depends'
attribute on the -build target controls the ordering of the
different build phases
===============================================================
-->
<target name="-before-build"/>
<target name="-build"
depends="refresh,
resolve,
js,
resources,
sass,
slice,
page,
native-package"/>
<target name="-after-build"/>
<target name="build"
depends="init,-before-build,-build,-after-build"
description="Builds the application"/>

<!--
===============================================================
Clean
removes all artifacts from the output build directories
===============================================================
-->
<target name="-before-clean"/>
<target name="-clean">
<delete dir="${build.dir}"/>
<delete dir="${build.temp.dir}"/>
</target>
<target name="-after-clean"/>
<target name="clean"
depends="init"
description="Removes all build output produced by the 'build' target">
<x-ant-call unless="skip.clean">
<target name="-before-clean"/>
<target name="-clean"/>
<target name="-after-clean"/>
</x-ant-call>
</target>

<!--
===============================================================
Watch
uses targets from watch-impl.xml to initiate the application
watch process using instrumented state from the compiler
===============================================================
-->
<import file="${basedir}/.sencha/app/watch-impl.xml"/>
<target name="watch">
<property name="build.optimize" value=""/>
<x-ant-call>
<target name="-before-watch"/>
<target name="-watch"/>
<target name="-after-watch"/>
</x-ant-call>
</target>

<!--
===============================================================
JS
uses targets from js-impl.xml to produce the output js files
containing needed application and framework js classes
===============================================================
-->

80,359

社区成员

发帖
与我相关
我的任务
社区描述
移动平台 Android
androidandroid-studioandroidx 技术论坛(原bbs)
社区管理员
  • Android
  • yechaoa
  • 失落夏天
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧