用详细的类加载运行Gradle? [英] Run Gradle with verbose class loading?

查看:155
本文介绍了用详细的类加载运行Gradle?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的构建脚本遇到错误(如下)。有没有一种方法可以使用与使用 -verbose:class



调用Java相同类型的输出来运行Gradle。有问题的错误,任何人都应该输入:

 原因:org.gradle.api.artifacts.ResolveException:Could not解决配置的所有依赖关系:Project:compile'。 
at org.gradle.api.internal.artifacts.ivyservice.ErrorHandlingArtifactDependencyResolver.wrapException(ErrorHandlingArtifactDependencyResolver.java:49)
...更多
引起:java.lang.LinkageError:加载器约束当链接org / apache / ivy / core / module / descriptor / DependencyDescriptor类时违反了这个规则。


解决方案您可以设置以下环境变量,我相信...

  GRADLE_OPTS =$ GRADLE_OPTS -verbose :class

然后调用 gradle 。阅读链接


一旦下载并解压Gradle,可以将环境变量
GRADLE_HOME设置为解压缩的Gradle
安装目录,并且PATH应该设置为$ GRADLE_HOME / bin或
%GRADLE_HOME%\bin。 Gradle安装页面告诉我们Gradle使用的JVM
选项可以通过GRADLE_OPTS或JAVA_OPTS来设置。
一旦环境变量
设置被获取,路径中的成绩安装和配置可以通过在命令行运行gradle -v来确认


blockquote>

My build script is encountering an error (below). Is there a way to run Gradle with the same type of output as invoking Java with -verbose:class?

The error in question, should anyone have some input:

Caused by: org.gradle.api.artifacts.ResolveException: Could not resolve all dependencies for configuration ':Project:compile'.
    at org.gradle.api.internal.artifacts.ivyservice.ErrorHandlingArtifactDependencyResolver.wrapException(ErrorHandlingArtifactDependencyResolver.java:49)
    ... more
Caused by: java.lang.LinkageError: loader constraints violated when linking org/apache/ivy/core/module/descriptor/DependencyDescriptor class

解决方案

You can set the following environment variable, I believe...

GRADLE_OPTS="$GRADLE_OPTS -verbose:class"

and then invoke gradle. Read this link.

Once Gradle is downloaded and unzipped, the environment variable GRADLE_HOME can be set to the directory of the unzipped Gradle installation and the PATH should be set to $GRADLE_HOME/bin or %GRADLE_HOME%\bin. The Gradle installation page tells us that JVM options used by Gradle can be set via either GRADLE_OPTS or JAVA_OPTS. The Grade installation and configuration in the path can be confirmed by running gradle -v at the command line once the environment variable settings are sourced.

这篇关于用详细的类加载运行Gradle?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆