Last active
June 24, 2019 16:38
-
-
Save albka1986/6e575099dfaa162382d28c93fd4942d9 to your computer and use it in GitHub Desktop.
gradle app
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apply plugin: 'com.android.application' | |
apply plugin: 'kotlin-android' | |
apply plugin: 'kotlin-android-extensions' | |
apply plugin: 'kotlin-kapt' | |
apply plugin: 'androidx.navigation.safeargs' | |
android { | |
android.applicationVariants.all { variant -> | |
variant.outputs.all { | |
outputFileName = "agent-${variant.name}-${variant.versionName}.apk" | |
} | |
} | |
compileSdkVersion 28 | |
defaultConfig { | |
applicationId "my.domain.app" | |
minSdkVersion 21 | |
targetSdkVersion 28 | |
versionCode 1 | |
versionName "0.5.5" | |
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" | |
signingConfig signingConfigs.debug | |
javaCompileOptions { | |
annotationProcessorOptions { | |
arguments = ["room.schemaLocation": "$projectDir/schemas".toString()] | |
} | |
} | |
} | |
buildTypes { | |
//QA | |
debug { | |
minifyEnabled false | |
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro' | |
buildConfigField "String", 'BASE_URL', "\"http://104.248.170.54/api/\"" | |
buildConfigField "String", 'PHOTO_URL', "\"http://104.248.170.54/\"" | |
} | |
//Stage | |
staging { | |
minifyEnabled false | |
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro' | |
buildConfigField "String", 'BASE_URL', "\"http://178.62.91.217/api/\"" | |
buildConfigField "String", 'PHOTO_URL', "\"http://178.62.91.217/\"" | |
debuggable true | |
} | |
release { | |
minifyEnabled false | |
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro' | |
buildConfigField "String", 'BASE_URL', "\"http://178.62.91.217/api/\"" | |
buildConfigField "String", 'PHOTO_URL', "\"http://178.62.91.217\"" | |
} | |
} | |
compileOptions { | |
sourceCompatibility JavaVersion.VERSION_1_8 | |
targetCompatibility JavaVersion.VERSION_1_8 | |
} | |
dataBinding { | |
enabled = true | |
} | |
} | |
dependencies { | |
implementation fileTree(dir: 'libs', include: ['*.jar']) | |
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" | |
implementation "org.jetbrains.kotlin:kotlin-reflect:$kotlin_version" | |
implementation 'androidx.appcompat:appcompat:1.1.0-beta01' | |
implementation "com.google.android.material:material:1.1.0-alpha07" | |
implementation 'androidx.core:core-ktx:1.2.0-alpha02' | |
implementation 'androidx.constraintlayout:constraintlayout:2.0.0-beta1' | |
implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-core:1.2.1' | |
implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-android:1.2.1' | |
//ViewModel & LiveData | |
implementation "androidx.lifecycle:lifecycle-extensions:$lifecycle_version" | |
implementation "androidx.lifecycle:lifecycle-common-java8:$lifecycle_version" | |
//Retrofit | |
implementation "com.squareup.retrofit2:retrofit:$retrofit_version" | |
implementation "com.squareup.retrofit2:converter-gson:$retrofit_version" | |
implementation 'com.squareup.okhttp3:logging-interceptor:3.9.1' | |
implementation 'com.jakewharton.retrofit:retrofit2-kotlin-coroutines-adapter:0.9.2' | |
// Room | |
implementation "androidx.room:room-runtime:$room_version" | |
implementation "androidx.legacy:legacy-support-v4:1.0.0" | |
kapt "androidx.room:room-compiler:$room_version" | |
// Gson | |
implementation "com.google.code.gson:gson:2.8.5" | |
// Navigation | |
implementation "androidx.navigation:navigation-fragment-ktx:$navigation_version" | |
implementation "androidx.navigation:navigation-ui-ktx:$navigation_version" | |
// Kodein | |
implementation "org.kodein.di:kodein-di-generic-jvm:$kodein_version" | |
implementation "org.kodein.di:kodein-di-framework-android-x:$kodein_version" | |
// Glide | |
implementation "com.github.bumptech.glide:glide:$glide_version" | |
kapt "com.github.bumptech.glide:compiler:$glide_version" | |
// Preference | |
implementation "androidx.preference:preference:1.0.0" | |
//Test | |
testImplementation 'junit:junit:4.13-beta-2' | |
androidTestImplementation 'androidx.test.ext:junit:1.1.1' | |
androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0' | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment