This repository has been archived by the owner on Nov 16, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 21
/
build.gradle
118 lines (108 loc) · 3.85 KB
/
build.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
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License.
*/
apply plugin: 'com.android.library'
apply plugin: 'kotlin-android'
apply plugin: 'kotlin-android-extensions'
apply plugin: 'maven-publish'
apply plugin: 'com.jfrog.bintray'
android {
compileSdkVersion 28
defaultConfig {
minSdkVersion 21
targetSdkVersion 28
versionCode 32
versionName '0.3.9'
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
vectorDrawables.useSupportLibrary = true
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
testOptions {
unitTests {
includeAndroidResources = true
}
}
productFlavors {
}
}
gradle.taskGraph.whenReady { taskGraph ->
taskGraph.allTasks.forEach {
if (it.name.contains("ReleaseUnitTest")) {
it.enabled = false
}
}
}
repositories {
maven { url "https://oss.sonatype.org/content/repositories/snapshots" }
}
dependencies {
implementation fileTree(include: ['*.jar'], dir: 'libs')
implementation 'com.android.support:appcompat-v7:28.0.0'
implementation 'com.android.support:exifinterface:28.0.0'
implementation 'com.android.support:recyclerview-v7:28.0.0'
implementation 'com.android.support:cardview-v7:28.0.0'
implementation 'com.android.support:design:28.0.0'
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
implementation 'com.jakewharton.threetenabp:threetenabp:1.1.0'
implementation 'com.splitwise:tokenautocomplete:2.0.8'
androidTestImplementation 'com.android.support.test:runner:1.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
testImplementation 'junit:junit:4.12'
testImplementation 'org.robolectric:robolectric:4.0-alpha-3'
}
task sourceJar(type: Jar) {
from android.sourceSets.main.java.srcDirs
classifier "sources"
}
publishing {
repositories {
maven {
url 'https://onedrive.pkgs.visualstudio.com/_packaging/fabric-android/maven/v1'
credentials {
username = project.hasProperty("mavenUserName") ? "$mavenUserName" : ""
password = project.hasProperty("mavenPassword") ? "$mavenPassword" : ""
}
}
}
publications {
OfficeUIFabric(MavenPublication) {
groupId 'com.microsoft.uifabric'
artifactId "$name"
version = android.defaultConfig.versionName
artifact(sourceJar)
artifact(bundleReleaseAar)
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.implementation.allDependencies.each {
if (it.group != null && (it.name != null && it.name != "unspecified") && it.version != null) {
def dependencyNode = dependenciesNode.appendNode('dependency')
dependencyNode.appendNode('groupId', it.group)
dependencyNode.appendNode('artifactId', it.name)
dependencyNode.appendNode('version', it.version)
}
}
}
}
}
}
bintray {
user = project.hasProperty('bintrayUser') ? "$bintrayUser" : ""
key = project.hasProperty('bintrayKey') ? "$bintrayKey" : ""
publications = ['OfficeUIFabric']
publish = true
pkg {
repo = 'generic'
name = 'ui-fabric-android'
version {
name = android.defaultConfig.versionName
vcsTag = android.defaultConfig.versionName
}
}
}