Skip to content

Commit

Permalink
Merge pull request #84 from theimpulson/kotlinDSL
Browse files Browse the repository at this point in the history
Migrate Gradle build scripts to Kotlin DSL
  • Loading branch information
fdff87554 authored Feb 10, 2024
2 parents c5318ef + c5afbcb commit 0aaa14e
Show file tree
Hide file tree
Showing 6 changed files with 111 additions and 110 deletions.
97 changes: 0 additions & 97 deletions app/build.gradle

This file was deleted.

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

android {
namespace = "app.opass.ccip"
compileSdk = 34

defaultConfig {
applicationId = "app.opass.ccip"
minSdk = 24
targetSdk = 34
versionCode = 53
versionName = "3.3.0"

manifestPlaceholders["manifestApplicationId"] = "$applicationId"
}

buildFeatures {
viewBinding = true
}

buildTypes {
release {
isMinifyEnabled = false
proguardFiles(
getDefaultProguardFile("proguard-android.txt"),
"proguard-rules.pro"
)
}
}
packaging {
resources {
excludes += listOf("META-INF/atomicfu.kotlin_module")
}
}


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

kotlinOptions {
jvmTarget = JavaVersion.VERSION_17.toString()
}

lint {
lintConfig = file("lint.xml")
}

androidResources {
generateLocaleConfig = true
}
}

dependencies {

implementation("com.google.firebase:firebase-analytics-ktx:21.5.0")
implementation("com.onesignal:OneSignal:[4.0.0, 4.99.99]")

implementation("androidx.appcompat:appcompat:1.6.1")
implementation("com.google.android.material:material:1.10.0")
implementation("androidx.recyclerview:recyclerview:1.3.2")
implementation("androidx.legacy:legacy-support-v4:1.0.0")
implementation("androidx.cardview:cardview:1.0.0")
implementation("androidx.core:core-ktx:1.12.0")
implementation("androidx.fragment:fragment-ktx:1.6.2")
implementation("androidx.viewpager2:viewpager2:1.0.0")
implementation("androidx.constraintlayout:constraintlayout:2.1.4")
implementation("com.google.android.flexbox:flexbox:3.0.0")
implementation("com.google.code.gson:gson:2.10.1")
implementation("com.squareup.okhttp3:okhttp:4.11.0")
implementation("com.squareup.retrofit2:retrofit:2.9.0")
implementation("com.squareup.retrofit2:converter-gson:2.9.0")
implementation("javax.annotation:jsr250-api:1.0")

implementation("com.squareup.picasso:picasso:2.71828")

implementation("com.journeyapps:zxing-android-embedded:4.3.0")

implementation("com.tbuonomo:dotsindicator:5.0")

// Coroutines
val coroutinesVersion = "1.7.3"
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:$coroutinesVersion")
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-android:$coroutinesVersion")

// Lifecycle
val lifecycleVersion = "2.6.2"
implementation("androidx.lifecycle:lifecycle-viewmodel-ktx:$lifecycleVersion")
implementation("androidx.lifecycle:lifecycle-livedata-ktx:$lifecycleVersion")

// Markwon
val markwonVersion = "4.6.2"
implementation("io.noties.markwon:core:$markwonVersion")
implementation("io.noties.markwon:linkify:$markwonVersion")

implementation("me.saket:better-link-movement-method:2.2.0")
}
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 /home/denny/.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
10 changes: 0 additions & 10 deletions build.gradle

This file was deleted.

6 changes: 6 additions & 0 deletions build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
// Top-level build file where you can add configuration options common to all sub-projects/modules.
plugins {
id("com.android.application") version "8.1.2" apply false
id("org.jetbrains.kotlin.android") version "1.9.10" apply false
id("com.google.gms.google-services") version "4.3.15" apply false
}
4 changes: 2 additions & 2 deletions settings.gradle → settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,5 @@ dependencyResolutionManagement {
mavenCentral()
}
}
include ':app'
rootProject.name = 'OPass'
include(":app")
rootProject.name = "OPass"

0 comments on commit 0aaa14e

Please sign in to comment.