forked from realm/realm-java
-
Notifications
You must be signed in to change notification settings - Fork 0
/
bintrayAnnotations.gradle
125 lines (117 loc) · 4.96 KB
/
bintrayAnnotations.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.2'
}
}
apply plugin: 'maven-publish'
apply plugin: 'com.jfrog.bintray'
def currentVersion = file("${projectDir}/version.txt").text.trim();
version = currentVersion
def commonPom = {
version = currentVersion
licenses {
license {
name 'The Apache Software License, Version 2.0'
url 'http://www.apache.org/licenses/LICENSE-2.0.txt'
distribution 'repo'
}
}
issueManagement {
system 'github'
url 'https://github.com/realm/realm-java/issues'
}
scm {
url 'scm:https://github.com/realm/realm-java'
connection 'scm:git@github.com:realm/realm-java.git'
developerConnection 'scm:git@github.com:realm/realm-java.git'
}
}
publishing {
publications {
jarLibrary(MavenPublication) {
groupId 'io.realm'
artifactId = 'realm-android'
artifact file("${buildDir}/outputs/gradle/realm-android-${currentVersion}.jar")
//artifact file("${rootDir}/realm/realm-library/build/libs/realm-android-${currentVersion}-sources.jar")
//artifact file("${rootDir}/realm/realm-library/build/libs/realm-android-${currentVersion}-javadoc.jar")
pom.withXml {
Node root = asNode()
root.appendNode('name', 'realm-android')
root.appendNode('description', 'Realm is a mobile database: a replacement for SQLite & ORMs.')
root.appendNode('url', 'http://realm.io')
root.children().last() + commonPom
}
}
aarLibrary(MavenPublication) {
groupId 'io.realm'
artifactId = 'realm-android-library'
artifact file("${rootDir}/realm/realm-library/build/outputs/aar/realm-library-release.aar")
//artifact file("${rootDir}/realm/realm-library/build/libs/realm-android-${currentVersion}-sources.jar")
//artifact file("${rootDir}/realm/realm-library/build/libs/realm-android-${currentVersion}-javadoc.jar")
pom.withXml {
Node root = asNode()
root.appendNode('name', 'realm-android-library')
root.appendNode('description', 'Realm is a mobile database: a replacement for SQLite & ORMs.')
root.appendNode('url', 'http://realm.io')
root.children().last() + commonPom
}
}
annotations(MavenPublication) {
groupId 'io.realm'
artifactId = 'realm-annotations'
artifact file("${rootDir}/realm/realm-annotations/build/libs/realm-annotations-${currentVersion}.jar")
pom.withXml {
Node root = asNode()
root.appendNode('name', 'realm-annotations')
root.appendNode('description', 'Annotations for Realm. Realm is a mobile database: a replacement for SQLite & ORMs')
root.appendNode('url', 'http://realm.io')
root.children().last() + commonPom
}
}
annotationsProcessor(MavenPublication) {
groupId 'io.realm'
artifactId = 'realm-annotations-processor'
artifact file("${rootDir}/realm/realm-annotations-processor/build/libs/realm-annotations-processor-${currentVersion}.jar")
pom.withXml {
Node root = asNode()
root.appendNode('name', 'realm-annotations-processor')
root.appendNode('description', 'Annotation Processor for Realm. Realm is a mobile database: a replacement for SQLite & ORMs')
root.appendNode('url', 'http://realm.io')
root.children().last() + commonPom
}
}
gradlePlugin(MavenPublication) {
groupId 'io.realm'
artifactId = 'realm-gradle-plugin'
artifact file("${rootDir}/gradle-plugin/build/libs/gradle-plugin-${currentVersion}.jar")
pom.withXml {
Node root = asNode()
root.appendNode('name', 'gradle-realm-plugin')
root.appendNode('description', 'Gradle plugin for Realm. Realm is a mobile database: a replacement for SQLite & ORMs.')
root.appendNode('url', 'http://realm.io')
root.children().last() + commonPom
}
}
}
}
bintray {
user = project.hasProperty('bintrayUser') ? bintrayUser : 'noUser'
key = project.hasProperty('bintrayKey') ? bintrayKey : 'noKey'
dryRun = false
publish = false
publications = ['annotations']
pkg {
repo = 'maven'
name = 'realm-annotations'
desc = 'Realm for Android'
websiteUrl = 'http://realm.io'
issueTrackerUrl = 'https://github.com/realm/realm-java/issues'
vcsUrl = 'https://github.com/realm/realm-java.git'
licenses = ['Apache-2.0']
labels = ['android', 'realm']
publicDownloadNumbers = false
}
}