无法从JCenter上下载我在Bintray上发布的文件 [英] Trouble downloading my published files on Bintray from JCenter

查看:667
本文介绍了无法从JCenter上下载我在Bintray上发布的文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在开发一个非常基本的Gradle插件(主要是为了获得经验),并且我已经发布了一个版本给我的Bintray仓库,该仓库应该是可见的这里



我已将我的存储库链接到JCenter(并可以找到我的插件 )现在,为了测试它的所有作品,我试图从Gradle构建脚本下载这些构件,并将我的插件应用到模拟项目中:

  apply plugin:'semver'
apply plugin:'java'

buildscript {
repositories {
jcenter ()
}
依赖项{
classpath'com.github.tagc:semver-plugin:0.1.0'
}
}

semver {
versionFilePath ='version.properties'
}
但是,Gradle无法解决该依赖关系并引发此异常:

 

失败:生成失败并出现异常。

*出错:
配置根项目'TestSemver'时出现问题。
>无法解析配置':classpath'的所有依赖关系。
>找不到com.github.tagc:semver-plugin:0.1.0。
在以下位置搜索:
https://jcenter.bintray.com/com/github/tagc/semver-plugin/0.1.0/semver-plugin-0.1.0.pom
https://jcenter.bintray.com/com/github/tagc/semver-plugin/0.1.0/semver-plugin-0.1.0.jar
要求:
:TestSemver:未指定

*尝试:
使用--stacktrace选项运行以获取堆栈跟踪。使用--info或--debug选项运行以获取更多日志输出。

建立失败

总时间:3.703秒

这是因为 JCenter 似乎没有托管我的文件(位于 com / github上/ TAGC )。我不确定为什么会出现这种情况。在确认我的存储库已与JCenter链接后,是否需要执行其他任何步骤以使其托管上传的文件,以便我可以按照构建脚本中显示的方式访问它们?或者只是需要一些时间让文件出现在JCenter上?自从我的存储库连接到JCenter以来,已经过去了大约5个小时。



任何帮助或建议都不胜感激。

解决方案

事实证明,我只需要耐心,让JCenter更新。 它现在在,我的构建脚本运行良好。



考虑到更新需要相当长的时间(对我来说大概需要12个小时),我认为可以通过让初次使用的用户知道有一个冗长的更新过程,他们并没有错过一个步骤。这会消除一些疑惑的焦虑:我错过了一步,如果是的话,我会永远等待吗?

那Bintray UX绝对是太棒了。

I'm developing a very basic Gradle plugin (mainly to get experience) and I've published a version to my Bintray repository which should be viewable here.

I've linked my repository to JCenter (and can find my plugin here) and now, to test it all works, I'm trying to download those artifacts from a Gradle build script and apply my plugin to a mock project:

apply plugin: 'semver'
apply plugin: 'java'

buildscript {
    repositories {
        jcenter()
    }
    dependencies {
        classpath 'com.github.tagc:semver-plugin:0.1.0'
    }
}

semver {
    versionFilePath = 'version.properties'
}

However, Gradle can't resolve that dependency and throws this exception:

FAILURE: Build failed with an exception.

* What went wrong:
A problem occurred configuring root project 'TestSemver'.
> Could not resolve all dependencies for configuration ':classpath'.
   > Could not find com.github.tagc:semver-plugin:0.1.0.
     Searched in the following locations:
         https://jcenter.bintray.com/com/github/tagc/semver-plugin/0.1.0/semver-plugin-0.1.0.pom
         https://jcenter.bintray.com/com/github/tagc/semver-plugin/0.1.0/semver-plugin-0.1.0.jar
     Required by:
         :TestSemver:unspecified

* 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: 3.703 secs

This is because JCenter doesn't seem to be hosting my files (under com/github/tagc). I'm not sure why this is the case. After getting a confirmation that my repository is linked with JCenter, are there any additional steps I need to take to make it host my uploaded files so that I can access them in the way shown in the build script? Or is just that it takes some time for the files to appear on JCenter? It's been about 5 hours since my repository was linked to JCenter.

Any help or advice would be appreciated.

解决方案

It turns out that I just needed to be patient and let JCenter update. It's on there now, and my build script runs fine.

Considering that it takes a fair amount of time to update (~12 hours for me), I think that the user experience might be improved by letting first-time users know that there's a lengthy update process and that they haven't simply missed a step. This would remove some of the anxiety of wondering "Have I missed a step, and if so will I be waiting forever?"

Other than that, the Bintray UX is absolutely wonderful.

这篇关于无法从JCenter上下载我在Bintray上发布的文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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