[英]Publish jar library to bintray using gradle
I'm trying to publish a jar library to bintray using Gradle. 我正在尝试使用Jardle将jar库发布为二进制文件。 I have a package on my project which is "com.github.instagram".
我的项目上有一个包“ com.github.instagram”。 What I am trying to achieve is to build the jar file of this package and upload it to bintray.
我想要实现的是构建此程序包的jar文件并将其上传到bintray。
here are my configurations 这是我的配置
uploadArchives {
repositories {
bintrayMavenDeployer {
username 'xxx'
apiKey 'xxx'
repoOwner 'xxx'
repoName 'xxx'
packageName 'xxx'
description 'This is an example to simplifying bintray publishing'
descUrl 'https://github.com/ysb33r/Gradle/blob/master/bintray/README.md'
tags 'gradle','bintray'
}
}
}
but when i execute gradlew uploadArchives, it uploads the apk file instead of jar library file. 但是当我执行gradlew uploadArchives时,它将上传apk文件而不是jar库文件。 how to instruct my gradle to compile only the package that I want and produce a jar file?
如何指示我的gradle仅编译所需的软件包并生成jar文件?
Please use the dedicated gradle-bintray-plugin . 请使用专用的gradle-bintray-plugin 。 The documentation include very detailed examples.
该文档包含非常详细的示例。
After you've created a Bintray account, I suggest you try using the following two scripts to make working with the gradle-bintray-plugin easier. 创建Bintray帐户后,建议您尝试使用以下两个脚本来简化gradle-bintray-plugin的使用。
https://raw.githubusercontent.com/attwellBrian/JCenter/master/installv1.gradle https://raw.githubusercontent.com/attwellBrian/JCenter/master/bintrayv1.gradle https://raw.githubusercontent.com/attwellBrian/JCenter/master/installv1.gradle https://raw.githubusercontent.com/attwellBrian/JCenter/master/bintrayv1.gradle
Please read the tutorial on how to use these scripts. 请阅读有关如何使用这些脚本的教程 。
The gradle-bintray-plugin is great. gradle-bintray-plugin很棒。 But its usage instructions at its GitHub page aren't straight forwards.
但是它在GitHub页面上的使用说明不是直接的。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.