-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathcommon.gradle
86 lines (71 loc) · 2.37 KB
/
common.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
subprojects {
repositories {
google()
jcenter()
mavenCentral()
mavenLocal()
maven { url 'https://maven.google.com' }
maven {url "https://clojars.org/repo/"}
}
}
def getAppVersionForSonar() {
if (System.env.bamboo_buildNumber != null) {
return "BAMBOO-${System.env.bamboo_buildNumber}"
}
def cmd = "git rev-parse --short HEAD"
def proc = cmd.execute()
return "GIT-" + proc.text.trim()
}
ext {
haloVersion = rootProject.hasProperty("production") ? file("${topDir}/version.txt").text.trim().replace("-SNAPSHOT", "") : file("${topDir}/version.txt").text.trim()
haloGroup = "com.mobgen.halo.android"
ignoreTestFailures = rootProject.hasProperty("ignoreTestFailures")
//Android config
compileSdkVersion = 28
buildToolsVersion = '28.0.3'
minSdkVersion = 15
minDemoAppVersion = 18
minLocationSdkVersion = 21
targetSdkVersion = 28
//Google
appcompatVersion = '28.0.0'
firebaseVersion = '11.8.0'
//Facebook
facebookSdkVersion = '4.27.0'
//Picasso
picassoVersion = '2.5.2'
//Glide
glideVersion = '3.7.0'
//Runtime
loganSquareVersion = '1.3.6'
okHttpVersion = '3.9.1'
//Code generation
javapoetVersion = '1.9.0'
autoServiceVersion = '1.0-rc4'
//Testing
jUnitVersion = '4.12'
assertJVersion = '3.9.0'
mockWebServerVersion = '3.9.1'
openGLTestLibrary = 'gl1.1-android-2.1_r1'
mockitoLibrary = '2.10.0'
robolectricLibrary = '3.8'
intellijAnnotations = '12.0'
//Jacoco
jacocoVersion = "0.8.0"
//Sonar
sonarVersion = getAppVersionForSonar()
sonarHost = System.getenv("HALO_SONAR_URL")
sonarDbHost = "${System.getenv('HALO_SONAR_DATABASE')}/sonar?useUnicode=true&characterEncoding=utf8&rewriteBatchedStatements=true&useConfigs=maxPerformance"
sonarUser = System.getenv("HALO_SONAR_USER")
sonarPassword = System.getenv("HALO_SONAR_PASSWORD")
//Distribution
sonatypeUser = System.getenv("HALO_SONATYPE_USER")
sonatypePassword = System.getenv("HALO_SONATYPE_PASSWORD")
jcenterUser = System.getenv("HALO_BINTRAY_USER")
jcenterKey = System.getenv("HALO_BINTRAY_KEY")
}
//Configures to reload all the time the dependencies
configurations.all {
resolutionStrategy.cacheChangingModulesFor 0, 'seconds'
resolutionStrategy.cacheDynamicVersionsFor 0, 'seconds'
}