Skip to content

Commit 45783e8

Browse files
committed
Checked in the bintray.gradle file.
1 parent 9003eeb commit 45783e8

2 files changed

Lines changed: 82 additions & 1 deletion

File tree

library/bintray.gradle

Lines changed: 81 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,81 @@
1+
group = PROJ_GROUP
2+
version = PROJ_VERSION
3+
project.archivesBaseName = PROJ_ARTIFACTID
4+
apply plugin: 'com.jfrog.bintray'
5+
apply plugin: 'maven-publish'
6+
task sourcesJar(type: Jar) {
7+
from android.sourceSets.main.java.srcDirs
8+
classifier = 'sources'
9+
}
10+
task javadoc(type: Javadoc) {
11+
source = android.sourceSets.main.java.srcDirs
12+
classpath += configurations.compile
13+
classpath += project.files(android.getBootClasspath().join(File.pathSeparator))
14+
}
15+
task javadocJar(type: Jar, dependsOn: javadoc) {
16+
classifier = 'javadoc'
17+
from javadoc.destinationDir
18+
}
19+
javadoc {
20+
options{
21+
encoding "UTF-8"
22+
charSet 'UTF-8'
23+
author true
24+
version true
25+
links "http://docs.oracle.com/javase/7/docs/api"
26+
title PROJ_ARTIFACTID
27+
}
28+
}
29+
artifacts {
30+
archives javadocJar
31+
archives sourcesJar
32+
}
33+
def pomConfig = {
34+
licenses {
35+
license {
36+
name "The Apache Software License, Version 2.0"
37+
url "http://www.apache.org/licenses/LICENSE-2.0.txt"
38+
distribution "repo"
39+
}
40+
}
41+
developers {
42+
developer {
43+
id DEVELOPER_ID
44+
name DEVELOPER_NAME
45+
email DEVELOPER_EMAIL
46+
}
47+
}
48+
}
49+
publishing {
50+
publications {
51+
mavenJava(MavenPublication) {
52+
artifactId PROJ_ARTIFACTID
53+
pom{
54+
packaging 'aar'
55+
}
56+
pom.withXml {
57+
def root = asNode()
58+
root.appendNode('description', PROJ_DESCRIPTION)
59+
root.children().last() + pomConfig
60+
}
61+
}
62+
}
63+
}
64+
bintray {
65+
user = hasProperty("bintrayUser")?getProperty("bintrayUser"):getProperty("BINTRAY_USER")
66+
key = hasProperty("bintrayKey")?getProperty("bintrayKey"):getProperty("BINTRAY_KEY")
67+
configurations = ['archives']
68+
publications = ['mavenJava']
69+
publish = true
70+
dryRun = true
71+
pkg {
72+
repo = 'maven'
73+
name = PROJ_NAME
74+
desc = PROJ_DESCRIPTION
75+
websiteUrl = PROJ_WEBSITEURL
76+
issueTrackerUrl = PROJ_ISSUETRACKERURL
77+
vcsUrl = PROJ_VCSURL
78+
licenses = ['Apache-2.0']
79+
publicDownloadNumbers = true
80+
}
81+
}

library/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,4 +36,4 @@ dependencies {
3636
}
3737

3838
// this script was used to upload files to bintray.
39-
apply from: 'https://raw.githubusercontent.com/msdx/gradle-publish/master/bintray.gradle'
39+
apply from: 'bintray.gradle'

0 commit comments

Comments
 (0)