2015-12-24 12:28:00 +01:00
|
|
|
apply plugin: 'com.android.application'
|
2017-10-22 15:37:36 +02:00
|
|
|
apply plugin: 'kotlin-android'
|
|
|
|
apply plugin: 'kotlin-android-extensions'
|
2015-12-24 12:28:00 +01:00
|
|
|
|
|
|
|
android {
|
2017-11-29 21:34:46 +01:00
|
|
|
compileSdkVersion 27
|
2018-01-22 11:10:13 +01:00
|
|
|
buildToolsVersion "27.0.3"
|
2016-04-25 22:45:24 +02:00
|
|
|
|
2015-12-24 12:28:00 +01:00
|
|
|
defaultConfig {
|
2016-02-28 15:56:08 +01:00
|
|
|
applicationId "com.simplemobiletools.calculator"
|
2015-12-24 12:28:00 +01:00
|
|
|
minSdkVersion 16
|
2017-11-29 21:34:46 +01:00
|
|
|
targetSdkVersion 27
|
2018-01-23 15:43:42 +01:00
|
|
|
versionCode 17
|
|
|
|
versionName "3.1.1"
|
2017-11-29 21:34:46 +01:00
|
|
|
setProperty("archivesBaseName", "calculator")
|
2015-12-29 12:49:48 +01:00
|
|
|
|
|
|
|
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
|
2015-12-24 12:28:00 +01:00
|
|
|
}
|
2016-04-25 22:23:03 +02:00
|
|
|
|
2016-04-25 22:19:28 +02:00
|
|
|
signingConfigs {
|
|
|
|
release
|
|
|
|
}
|
2016-04-25 22:23:03 +02:00
|
|
|
|
2015-12-24 12:28:00 +01:00
|
|
|
buildTypes {
|
2018-01-30 22:05:44 +01:00
|
|
|
debug {
|
|
|
|
applicationIdSuffix ".debug"
|
|
|
|
}
|
2015-12-24 12:28:00 +01:00
|
|
|
release {
|
2016-01-04 23:19:39 +01:00
|
|
|
minifyEnabled true
|
2015-12-24 12:28:00 +01:00
|
|
|
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
|
2016-04-25 22:19:28 +02:00
|
|
|
signingConfig signingConfigs.release
|
2015-12-24 12:28:00 +01:00
|
|
|
}
|
|
|
|
}
|
2017-11-05 16:25:01 +01:00
|
|
|
|
2017-11-05 16:28:27 +01:00
|
|
|
sourceSets {
|
|
|
|
main.java.srcDirs += 'src/main/kotlin'
|
|
|
|
}
|
|
|
|
|
2017-11-05 16:25:01 +01:00
|
|
|
lintOptions {
|
|
|
|
checkReleaseBuilds false
|
|
|
|
abortOnError false
|
|
|
|
}
|
2015-12-24 12:28:00 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
dependencies {
|
2018-02-27 20:43:15 +01:00
|
|
|
implementation 'com.simplemobiletools:commons:3.13.16'
|
2017-11-29 21:34:46 +01:00
|
|
|
implementation 'me.grantland:autofittextview:0.2.1'
|
2016-06-01 18:00:18 +02:00
|
|
|
|
2017-11-29 21:34:46 +01:00
|
|
|
testImplementation 'junit:junit:4.12'
|
|
|
|
testImplementation 'org.robolectric:robolectric:3.5.1'
|
2016-01-31 20:45:37 +01:00
|
|
|
|
2017-11-30 19:04:26 +01:00
|
|
|
androidTestImplementation 'com.android.support:support-annotations:27.0.2'
|
2017-11-29 21:34:46 +01:00
|
|
|
androidTestImplementation 'com.android.support.test:runner:1.0.1'
|
|
|
|
androidTestImplementation 'com.android.support.test:rules:1.0.1'
|
|
|
|
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.1'
|
2017-11-05 16:25:01 +01:00
|
|
|
}
|
|
|
|
|
2017-11-29 21:34:46 +01:00
|
|
|
Properties props = new Properties()
|
2016-04-25 22:19:28 +02:00
|
|
|
def propFile = new File('signing.properties')
|
|
|
|
if (propFile.canRead()) {
|
|
|
|
props.load(new FileInputStream(propFile))
|
|
|
|
|
2017-11-05 16:25:01 +01:00
|
|
|
if (props != null && props.containsKey('STORE_FILE') && props.containsKey('KEY_ALIAS') && props.containsKey('PASSWORD')) {
|
2016-04-25 22:19:28 +02:00
|
|
|
android.signingConfigs.release.storeFile = file(props['STORE_FILE'])
|
2017-11-05 16:25:01 +01:00
|
|
|
android.signingConfigs.release.storePassword = props['PASSWORD']
|
2016-04-25 22:19:28 +02:00
|
|
|
android.signingConfigs.release.keyAlias = props['KEY_ALIAS']
|
2017-11-05 16:25:01 +01:00
|
|
|
android.signingConfigs.release.keyPassword = props['PASSWORD']
|
2016-04-25 22:19:28 +02:00
|
|
|
} else {
|
|
|
|
println 'signing.properties found but some entries are missing'
|
|
|
|
android.buildTypes.release.signingConfig = null
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
println 'signing.properties not found'
|
|
|
|
android.buildTypes.release.signingConfig = null
|
|
|
|
}
|