Skip to content

Commit

Permalink
Migrate to KotlinDSL and remove something
Browse files Browse the repository at this point in the history
  • Loading branch information
AlirezaIvaz committed Jun 21, 2023
1 parent 267f7d2 commit 705197c
Show file tree
Hide file tree
Showing 6 changed files with 77 additions and 99 deletions.
93 changes: 0 additions & 93 deletions app/build.gradle

This file was deleted.

71 changes: 71 additions & 0 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
plugins {
id("com.android.application")
id("kotlin-android")
}

android {
namespace = "com.franco.demomode"
compileSdk = 33

defaultConfig {
applicationId = "com.franco.demomode"
minSdk = 24
targetSdk = 33
versionName = "1.6"
versionCode = 1910030257
}

compileOptions {
sourceCompatibility = JavaVersion.VERSION_11
targetCompatibility = JavaVersion.VERSION_11
}

lintOptions {
isAbortOnError = false
isCheckAllWarnings = false
disable("InvalidPackage")
}

packagingOptions {
exclude("META-INF/LICENSE.txt")
exclude("META-INF/NOTICE.txt")
}

buildTypes {
release {
isDebuggable = false
isMinifyEnabled = true
isShrinkResources = true
proguardFiles(
getDefaultProguardFile("proguard-android-optimize.txt"),
"proguard-rules.pro"
)
}

debug {
isMinifyEnabled = false
isShrinkResources = false
}
}

buildFeatures {
viewBinding = true
}
kotlinOptions {
jvmTarget = "11"
}
}

dependencies {
implementation("androidx.appcompat:appcompat:1.6.1")
implementation("com.google.android.material:material:1.9.0")
implementation("androidx.preference:preference-ktx:1.2.0")
implementation("androidx.fragment:fragment-ktx:1.5.7")
implementation("androidx.core:core-ktx:1.10.1")
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:1.6.4")

val lifecycle_version = "2.6.1"
implementation("androidx.lifecycle:lifecycle-viewmodel-ktx:$lifecycle_version")
implementation("androidx.lifecycle:lifecycle-livedata-ktx:$lifecycle_version")
implementation("androidx.lifecycle:lifecycle-common-java8:$lifecycle_version")
}
2 changes: 1 addition & 1 deletion app/proguard-rules.pro
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# By default, the flags in this file are appended to flags specified
# in /usr/local/opt/android-sdk/tools/proguard/proguard-android.txt
# You can edit the include path and order by changing the proguardFiles
# directive in build.gradle.
# directive in build.gradle.kts.
#
# For more details, see
# http://developer.android.com/guide/developing/tools/proguard.html
Expand Down
4 changes: 0 additions & 4 deletions build.gradle

This file was deleted.

4 changes: 4 additions & 0 deletions build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
plugins {
id("com.android.application") version "8.0.2" apply false
id("org.jetbrains.kotlin.android") version "1.8.0" apply false
}
2 changes: 1 addition & 1 deletion settings.gradle → settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@ dependencyResolutionManagement {
mavenCentral()
}
}
include ':app'
include(":app")

0 comments on commit 705197c

Please sign in to comment.