本文介绍了Gradle:如何使用特定版本的快照?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用graphap库的SNAPSHOT版本.

I'm using SNAPSHOT version of graphhopper library.

是否可以使用旧版本的快照? 我试过了:

Is there posibility to use older version of snapshot? I tried:

 compile(group: 'com.graphhopper', name: 'graphhopper', version: '0.6-20151126.110118-54') {

    exclude group: 'com.google.protobuf', module: 'protobuf-java'
    exclude group: 'org.openstreetmap.osmosis', module: 'osmosis-osm-binary'
    exclude group: 'org.apache.xmlgraphics', module: 'xmlgraphics-commons'
}

作为存储库,我使用:maven { url "https://oss.sonatype.org/content/groups/public/" }

As repository I use: maven { url "https://oss.sonatype.org/content/groups/public/" }

我也尝试了这个存储库:

I've tried also this repository:

maven {url "https://oss.sonatype.org/content/repositories/snapshots/"}

但也找不到.

Could not find com.graphhopper:graphhopper:0.6-20151126.110118-54.
 Searched in the following locations:
     https://jcenter.bintray.com/com/graphhopper/graphhopper/0.6-20151126.110118-54/graphhopper-0.6-20151126.110118-54.pom
     https://jcenter.bintray.com/com/graphhopper/graphhopper/0.6-20151126.110118-54/graphhopper-0.6-20151126.110118-54.jar
     https://oss.sonatype.org/content/groups/public/com/graphhopper/graphhopper/0.6-20151126.110118-54/graphhopper-0.6-20151126.110118-54.pom
     https://oss.sonatype.org/content/groups/public/com/graphhopper/graphhopper/0.6-20151126.110118-54/graphhopper-0.6-20151126.110118-54.jar
     file:/D:/adt-bundle-windows-x86/sdk/extras/android/m2repository/com/graphhopper/graphhopper/0.6-20151126.110118-54/graphhopper-0.6-20151126.110118-54.pom
     file:/D:/adt-bundle-windows-x86/sdk/extras/android/m2repository/com/graphhopper/graphhopper/0.6-20151126.110118-54/graphhopper-0.6-20151126.110118-54.jar
     file:/D:/adt-bundle-windows-x86/sdk/extras/google/m2repository/com/graphhopper/graphhopper/0.6-20151126.110118-54/graphhopper-0.6-20151126.110118-54.pom
     file:/D:/adt-bundle-windows-x86/sdk/extras/google/m2repository/com/graphhopper/graphhopper/0.6-20151126.110118-54/graphhopper-0.6-20151126.110118-54.jar

我也尝试过使用gradle缓存的本地路径(删除最新的快照目录并保留要使用的版本后),但没有成功.如果不可能,是否有任何方法可以停止下载新的SNAPSNOT版本?

I have tried also using local path to the gradle cache (after deleting newest snapshot dirs and leaving version I want to use) but no success. If it's impossible, is there any way to stop downloading new SNAPSNOT versions?

感谢您的帮助.

推荐答案

查看此链接: https ://issues.gradle.org/browse/GRADLE-2784 应该在四月修复.您使用哪个Gradle版本?

Check out this link: https://issues.gradle.org/browse/GRADLE-2784 Should have been fixed in April. Which Gradle version do you use?

这篇关于Gradle:如何使用特定版本的快照?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

07-30 22:47