I am using bintray gradle plugin to upload java artifact on Bintray. I have written this code from example, it creates package and version successfully but there are not files in files directory. What am I missing here??
bintray {
user = 'user name'
key = 'my key'
pkg {
repo = 'androids'
name = 'name'
licenses = ['Apache-2.0']
vcsUrl = 'https://github.com/bintray/gradle-bintray-plugin.git'
version {
name = 'version'
desc = 'Gradle Bintray Plugin 1.0 final'
released = new Date()
vcsTag = '1.3.0'
attributes = ['gradle-plugin': 'com.use.less:com.use.less.gradle:gradle-useless-plugin']
}
filesSpec {
from 'build/libs'
into 'standalone_files/level1'
}
}
}
I was running the task from root project where build directory was not defined. When I ran it from with in the module where (build/libs) contains required artifacts.
From your tag I assume you are working on an Android project. I had a similar problem. Then I realized build/lib
from the plugin documentation is just a placeholder. I had to set mine to where my library's aar was stored:
filesSpec {
from 'build/outputs/aar'
into '.'
}
If you're ever unclear you can always just upload current directory, see what actually gets uploaded to Bintray, and then get a gauge of where it's actually looking:
filesSpec {
from '.'
into '.'
}
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.