首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >Bintray标记

Bintray标记
EN

Stack Overflow用户
提问于 2015-11-23 16:25:25
回答 1查看 519关注 0票数 0

所以我有一个Bintray存储库,但是我很难从gradle上传到它。好的,我的意思是版本管理没有按我所希望的方式工作,目前,对于我上传的每一个.jar,我必须在配置和依赖项中增加版本。我知道这不是该怎么做的。我的问题是,我如何自动化/实现VCS标记与Bintray。现在,我的上传配置如下所示(使用bin托盘插件):

代码语言:javascript
复制
bintray {
user = "$bintrayUser"
key = "$bintrayKey"
publications = ['maven']
dryRun = false
publish = true
pkg {
    repo = "$targetBintrayRepo"
    name = "$targetBintrayPackage"
    desc = ''
    websiteUrl = "$programWebsiteUrl"
    issueTrackerUrl = "$programIssueUrl"
    vcsUrl = "$programVcsUrl"
    licenses = ["$programLicense"]
    labels = []
    publicDownloadNumbers = true

    version {
        name = "$programVersion"
        released = new java.util.Date()
        vcsTag = "$programVcsTag"
    }

}
}

我的变量是:

代码语言:javascript
复制
def programVersion = '0'
def programVcsTag = '0.0.0'
def programGroup = 'com.gmail.socraticphoenix'
def targetBintrayRepo = 'Main'
def targetBintrayPackage = 'java-api'
def programLicense = 'MIT'
def programWebsiteUrl = 'https://github.com/meguy26/PlasmaAPI'
def programIssueUrl = 'https://github.com/meguy26/PlasmaAPI/issues'
def programVcsUrl = 'https://github.com/meguy26/PlasmaAPI.git'

然而,这里没有出现标记,并且再次运行发布(即使使用不同的vcs标记)会导致版本已经存在错误。(Could not upload to 'https://api.bintray.com/content/meguy26/Main/java-api/0/com/gmail/socraticphoenix/PlasmaAPI/0/PlasmaAPI-0.jar': HTTP/1.1 409 Conflict [message:Unable to upload files: An artifact with the path 'com/gmail/socraticphoenix/PlasmaAPI/0/PlasmaAPI-0.jar' already exists])

对不起,如果我是个无名氏,但我不明白为什么它不工作,我填写了所有适当的变量(我想)

EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2015-11-23 17:48:47

每个版本不支持多个标签。版本是唯一的字符串。如果您想用不同的标记从同一版本中发布某些内容,请使用您的程序版本和标记(例如,"$programVersion-$programVcsTag" )组成一个Bintray版本字符串。

票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/33875817

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档