-
Notifications
You must be signed in to change notification settings - Fork 12
Expand file tree
/
Copy pathbuild.gradle
More file actions
102 lines (89 loc) · 2.97 KB
/
Copy pathbuild.gradle
File metadata and controls
102 lines (89 loc) · 2.97 KB
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
apply plugin: 'com.android.library'
apply plugin: 'com.jfrog.bintray'
apply plugin: 'maven-publish'
version '0.2.6-43-1'
project.version = this.version
task sourceJar(type: Jar) {
from android.sourceSets.main.java.srcDirs
classifier "sources"
}
artifacts {
archives sourceJar
}
publishing {
publications {
Production(MavenPublication) {
artifact("$buildDir/outputs/aar/utils-release.aar")
artifact(sourceJar)
groupId 'io.ona.kujaku'
artifactId 'utils'
version this.version
//The publication doesn't know about our dependencies, so we have to manually add them to the pom
pom.withXml {
def dependenciesNode = asNode().appendNode('dependencies')
//Iterate over the compile dependencies (we don't want the test ones), adding a <dependency> node for each
configurations.compile.allDependencies.each {
def dependencyNode = dependenciesNode.appendNode('dependency')
dependencyNode.appendNode('groupId', it.group)
dependencyNode.appendNode('artifactId', it.name)
dependencyNode.appendNode('version', it.version)
}
}
}
}
}
bintray {
// Get Bintray credential from environment variable
user = System.getenv('BINTRAY_USER') // Get bintray User
key = System.getenv('BINTRAY_KEY') // Get bintray Secret Key
configurations = ['archives']
pkg {
repo = 'kujaku'
name = project.name
userOrg = 'jasonrogena'
licenses = ['Apache-2.0']
desc = 'Kujaku utils'
websiteUrl = "https://github.com/jasonrogena"
publish = true
vcsUrl = "https://github.com/onaio/kujaku.git"
version {
name = this.version
desc = "Kujaku utils version ${this.version}"
released = new Date()
vcsTag = this.version
}
}
publications = ['Production']
}
android {
compileSdkVersion 26
buildToolsVersion "26.0.2"
defaultConfig {
minSdkVersion 16
targetSdkVersion 26
versionCode 1
versionName this.version
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
lintOptions {
abortOnError false
}
}
dependencies {
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
exclude group: 'com.android.support', module: 'support-annotations'
})
compile 'com.android.support:appcompat-v7:26.1.0'
compile 'com.cocoahero.android:geojson:1.0.1@jar'
compile('com.mapbox.mapboxsdk:mapbox-android-sdk:5.2.0-beta.3@aar') {
transitive = true
}
testCompile 'junit:junit:4.12'
testCompile 'org.robolectric:robolectric:3.5.1'
}