开发者社区> 问答> 正文

Jenkins+svn使用gradle构建Android项目报错求大神帮忙看看?报错

[zhsq] $ cmd.exe /C "C:\Users\zzq\.gradle\wrapper\dists\gradle-3.3-all\55gk2rcmfc6p2dg9u9ohc3hw9\gradle-3.3\bin\gradle.bat clean -PAPP_VERSION=1.0.1 -PIS_JENKINS=true -PPRODUCT_FLAVOR=App -PSERVICE_BASE_URL=http://127.0.0.1 assembleAppDebug && exit %%ERRORLEVEL%%"

FAILURE: Build failed with an exception.

* Where:
Build file 'C:\Users\zzq\.jenkins\workspace\zhsq\build.gradle' line: 1

* What went wrong:
A problem occurred evaluating root project 'zhsq'.
> Plugin with id 'com.android.application' not found.

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

BUILD FAILED

Total time: 4.537 secs
Build step 'Invoke Gradle script' changed build result to FAILURE
Build step 'Invoke Gradle script' marked build as failure
Set build name.
New build name is '#2-1.0.1-App-Debug'
Archiving artifacts
Finished: FAILURE

 

展开
收起
爱吃鱼的程序员 2020-06-07 17:27:12 984 0
1 条回答
写回答
取消 提交回答
  • https://developer.aliyun.com/profile/5yerqm5bn5yqg?spm=a2c6h.12873639.0.0.6eae304abcjaIB
                        <p>一般都是gradle版本和针对android项目进行编译的gradle插件版本不兼容导致的。</p> 
    

    查看下工程目录的build.gradle中如下声明语句中的版本号,确定该版本号是否同gradle版本兼容

    classpath 'com.android.tools.build:gradle:3.1.0'

     

    2020-06-07 17:27:32
    赞同 展开评论 打赏
问答排行榜
最热
最新

相关电子书

更多
Android热修复技术原理详解与升级探索 立即下载
Android内存泄漏自动化链路分析组件Probe 立即下载
58同城Android客户端Walle框架演进与实践之路 立即下载