将android build tools gradle插件从0.14.0升级到1.0.0后,我无法再使用命令' gradle runDebug'在我的USB连接设备上运行我的调试版本。
但是,所有其他gradle命令都有效(测试,清理构建,构建)。
这是堆栈:
Execution failed for task ':myAndroidApp:installDeviceDebug'.
> Could not find property 'packageApplication' on
com.android.build.gradle.internal.api.ApplicationVariantImpl_Decorated@4001495a.
org.gradle.api.tasks.TaskExecutionException: Execution failed for task
':myAndroidApp:installDeviceDebug'.
Caused by: groovy.lang.MissingPropertyException: Could not find property 'packageApplication' on
com.android.build.gradle.internal.api.ApplicationVariantImpl_Decorated@4001495a.
at
org.gradle.api.internal.AbstractDynamicObject.propertyMissingException(AbstractDynamicObject.java:43)
at org.gradle.api.internal.AbstractDynamicObject.getProperty(AbstractDynamicObject.java:35)
at org.gradle.api.internal.CompositeDynamicObject.getProperty(CompositeDynamicObject.java:94)
at com.android.build.gradle.internal.api.ApplicationVariantImpl_Decorated.getProperty(Unknown Source)
at com.novoda.gradle.command.VariantConfigurator$_configure_closure2.doCall(VariantConfigurator.groovy:29)
at com.novoda.gradle.command.AdbCommand.toString(AdbCommand.groovy:19)
at com.novoda.gradle.command.AdbTask.runCommand(AdbTask.groovy:35)
at com.novoda.gradle.command.Install.exec(Install.groovy:9)
当前工具
Gradle Build设置
答案 0 :(得分:3)
我通过将'com.novoda:gradle-android-command-plugin:1.2.1'升级到'com.novoda:gradle-android-command-plugin:1.3.0'来修复此问题。