Skip to content

Commit 6b5a457

Browse files
authored
Merge pull request #482 from lucasnlm/new-build
Migrate gradle to gradle.kts
2 parents ee56dfc + 2b3d62d commit 6b5a457

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

71 files changed

+1824
-1887
lines changed

.github/workflows/android.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
- name: Run script
1616
run: |
1717
chmod +x ./gdx/check_import.sh
18-
bash ./gdx/check_import.sh ./gdx/build.gradle
18+
bash ./gdx/check_import.sh ./gdx/build.gradle.kts
1919
shell: bash
2020

2121
ktlint:

about/build.gradle

Lines changed: 0 additions & 80 deletions
This file was deleted.

about/build.gradle.kts

Lines changed: 82 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,82 @@
1+
plugins {
2+
id("com.android.library")
3+
id("kotlin-android")
4+
}
5+
6+
android {
7+
namespace = "dev.lucasnlm.antimine.about"
8+
9+
defaultConfig {
10+
minSdk = libs.versions.minSdk.get().toInt()
11+
compileSdk = libs.versions.compileSdk.get().toInt()
12+
13+
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
14+
consumerProguardFiles("consumer-rules.pro")
15+
}
16+
17+
buildTypes {
18+
release {
19+
isMinifyEnabled = false
20+
setProguardFiles(listOf(getDefaultProguardFile("proguard-android-optimize.txt"), "proguard-rules.pro"))
21+
}
22+
}
23+
24+
compileOptions {
25+
sourceCompatibility = JavaVersion.VERSION_11
26+
targetCompatibility = JavaVersion.VERSION_11
27+
}
28+
29+
kotlinOptions {
30+
jvmTarget = JavaVersion.VERSION_11.toString()
31+
}
32+
33+
buildFeatures {
34+
buildConfig = true
35+
viewBinding = true
36+
}
37+
}
38+
39+
dependencies {
40+
implementation(project(":core"))
41+
implementation(project(":i18n"))
42+
implementation(project(":preferences"))
43+
implementation(project(":ui"))
44+
implementation(project(":utils"))
45+
implementation(project(":tutorial"))
46+
implementation(project(":external"))
47+
48+
// Google
49+
implementation(libs.material)
50+
51+
// AndroidX
52+
implementation(libs.appcompat)
53+
implementation(libs.activity.ktx)
54+
implementation(libs.fragment.ktx)
55+
56+
// RecyclerView
57+
implementation(libs.recyclerview)
58+
59+
// Constraint
60+
implementation(libs.constraintlayout)
61+
62+
// Lifecycle
63+
implementation(libs.lifecycle.viewmodel.ktx)
64+
65+
// Koin
66+
implementation(libs.koin.android)
67+
testImplementation(libs.koin.test)
68+
69+
// Coroutines
70+
implementation(libs.kotlinx.coroutines.core)
71+
implementation(libs.kotlinx.coroutines.android)
72+
testImplementation(libs.kotlinx.coroutines.test)
73+
74+
// Kotlin Lib
75+
implementation(libs.kotlin.stdlib)
76+
77+
// Unit Tests
78+
testImplementation(libs.junit)
79+
testImplementation(libs.mockito.core)
80+
testImplementation(libs.mockito.kotlin)
81+
testImplementation(libs.mockk)
82+
}

about/proguard-rules.pro

Lines changed: 3 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,3 @@
1-
# Add project specific ProGuard rules here.
2-
# You can control the set of applied configuration files using the
3-
# proguardFiles setting in build.gradle.
4-
#
5-
# For more details, see
6-
# http://developer.android.com/guide/developing/tools/proguard.html
7-
8-
# If your project uses WebView with JS, uncomment the following
9-
# and specify the fully qualified class name to the JavaScript interface
10-
# class:
11-
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
12-
# public *;
13-
#}
14-
15-
# Uncomment this to preserve the line number information for
16-
# debugging stack traces.
17-
#-keepattributes SourceFile,LineNumberTable
18-
19-
# If you keep the line number information, uncomment this to
20-
# hide the original source file name.
21-
#-renamesourcefileattribute SourceFile
1+
-dontwarn java.lang.invoke.StringConcatFactory
2+
-dontwarn com.google.android.material.R$attr
3+
-dontwarn dev.lucasnlm.antimine.i18n.R$string

0 commit comments

Comments
 (0)