gpt4 book ai didi

Android、Azure Devops 在运行管道时出错 ##[error]Error : The process '/Users/runner/work/1/s/gradlew' failed with exit code 1

转载 作者:行者123 更新时间:2023-12-04 23:54:43 25 4
gpt4 key购买 nike

Android,Azure Devops 在运行管道时出错 ##[error]Error: The process '/Users/runner/work/1/s/gradlew' failed with exit code 1
在语言环境系统中,所有正常工作的 apk 都生成了,但是当在 azure devops 上运行管道时,它显示错误

FAILURE: Build failed with an exception.

* Where: Build file '/Users/runner/work/1/s/app/build.gradle' line: 2

* What went wrong: An exception occurred applying plugin request [id:
'com.android.application']
> Failed to apply plugin 'com.android.internal.application'.
> Android Gradle plugin requires Java 11 to run. You are currently using Java 1.8.
我已经在使用 Java 11
我搜索了相同但没有得到任何解决方案。

最佳答案

我通过在 azure-pipelines.yml 中添加 maven 任务解决了这个问题

steps:
- task: Maven@3
inputs:
mavenPomFile: 'pom.xml'
publishJUnitResults: false
javaHomeOption: 'JDKVersion'
jdkVersionOption: '1.11'
mavenVersionOption: 'Default'
mavenOptions: '-Xmx3072m'
希望这将有助于其他...

关于Android、Azure Devops 在运行管道时出错 ##[error]Error : The process '/Users/runner/work/1/s/gradlew' failed with exit code 1,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/71583663/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com