Skip to content

Commit c8c4684

Browse files
committed
chore: version catalog init
1 parent 47067d7 commit c8c4684

41 files changed

Lines changed: 517 additions & 173 deletions

Some content is hidden

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

.idea/compiler.xml

Lines changed: 5 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/gradle.xml

Lines changed: 15 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/kotlinc.xml

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/misc.xml

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

app/build.gradle.kts

Lines changed: 7 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
1+
@Suppress("DSL_SCOPE_VIOLATION")
12
plugins {
2-
id("com.android.application")
3-
id("org.jetbrains.kotlin.android")
3+
alias(libs.plugins.moneymong.android.application)
4+
alias(libs.plugins.moneymong.android.application.compose)
5+
alias(libs.plugins.moneymong.android.application.flavors)
6+
// alias(libs.plugins.moneymong.android.hilt) hilt compiler was found error
47
}
58

69
android {
@@ -30,11 +33,8 @@ android {
3033
}
3134
}
3235
compileOptions {
33-
sourceCompatibility = JavaVersion.VERSION_1_8
34-
targetCompatibility = JavaVersion.VERSION_1_8
35-
}
36-
kotlinOptions {
37-
jvmTarget = "1.8"
36+
sourceCompatibility = JavaVersion.VERSION_17
37+
targetCompatibility = JavaVersion.VERSION_17
3838
}
3939
buildFeatures {
4040
compose = true
@@ -69,28 +69,4 @@ android {
6969
}
7070

7171
dependencies {
72-
implementation(project(":data"))
73-
implementation(project(":domain"))
74-
implementation(project(":di"))
75-
implementation(project(":design-system"))
76-
77-
implementation(project(":feature:sign"))
78-
79-
implementation(project(":core:ui"))
80-
81-
implementation("androidx.core:core-ktx:1.9.0")
82-
implementation("androidx.lifecycle:lifecycle-runtime-ktx:2.6.1")
83-
implementation("androidx.activity:activity-compose:1.7.0")
84-
implementation(platform("androidx.compose:compose-bom:2023.03.00"))
85-
implementation("androidx.compose.ui:ui")
86-
implementation("androidx.compose.ui:ui-graphics")
87-
implementation("androidx.compose.ui:ui-tooling-preview")
88-
implementation("androidx.compose.material3:material3")
89-
testImplementation("junit:junit:4.13.2")
90-
androidTestImplementation("androidx.test.ext:junit:1.1.5")
91-
androidTestImplementation("androidx.test.espresso:espresso-core:3.5.1")
92-
androidTestImplementation(platform("androidx.compose:compose-bom:2023.03.00"))
93-
androidTestImplementation("androidx.compose.ui:ui-test-junit4")
94-
debugImplementation("androidx.compose.ui:ui-tooling")
95-
debugImplementation("androidx.compose.ui:ui-test-manifest")
9672
}
Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
2+
3+
@Suppress("DSL_SCOPE_VIOLATION") // TODO: Remove once KTIJ-19369 is fixed
4+
plugins {
5+
`kotlin-dsl`
6+
}
7+
8+
group = "com.moneymong.moneymong.buildlogic.convention"
9+
10+
java {
11+
sourceCompatibility = JavaVersion.VERSION_17
12+
targetCompatibility = JavaVersion.VERSION_17
13+
}
14+
tasks.withType<KotlinCompile>().configureEach {
15+
kotlinOptions {
16+
jvmTarget = JavaVersion.VERSION_17.toString()
17+
}
18+
}
19+
20+
dependencies {
21+
compileOnly(libs.android.gradlePlugin)
22+
compileOnly(libs.android.tools.common)
23+
compileOnly(libs.kotlin.gradlePlugin)
24+
compileOnly(libs.ksp.gradlePlugin)
25+
}
26+
27+
gradlePlugin {
28+
plugins {
29+
register("androidApplicationCompose") {
30+
id = "moneymong.android.application.compose"
31+
implementationClass = "AndroidApplicationComposeConventionPlugin"
32+
}
33+
register("androidApplication") {
34+
id = "moneymong.android.application"
35+
implementationClass = "AndroidApplicationConventionPlugin"
36+
}
37+
register("androidLibraryCompose") {
38+
id = "moneymong.android.library.compose"
39+
implementationClass = "AndroidLibraryComposeConventionPlugin"
40+
}
41+
register("androidLibrary") {
42+
id = "moneymong.android.library"
43+
implementationClass = "AndroidLibraryConventionPlugin"
44+
}
45+
register("androidFeature") {
46+
id = "moneymong.android.feature"
47+
implementationClass = "AndroidFeatureConventionPlugin"
48+
}
49+
register("androidHilt") {
50+
id = "moneymong.android.hilt"
51+
implementationClass = "AndroidHiltConventionPlugin"
52+
}
53+
register("androidFlavors") {
54+
id = "moneymong.android.application.flavors"
55+
implementationClass = "AndroidApplicationFlavorsConventionPlugin"
56+
}
57+
register("jvmLibrary") {
58+
id = "moneymong.jvm.library"
59+
implementationClass = "JvmLibraryConventionPlugin"
60+
}
61+
}
62+
}
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
import com.android.build.api.dsl.ApplicationExtension
2+
import com.moneymong.moneymong.buildlogic.convention.configureAndroidCompose
3+
import org.gradle.api.Plugin
4+
import org.gradle.api.Project
5+
import org.gradle.kotlin.dsl.getByType
6+
7+
class AndroidApplicationComposeConventionPlugin : Plugin<Project> {
8+
override fun apply(target: Project) {
9+
with(target) {
10+
pluginManager.apply("com.android.application")
11+
12+
val extension = extensions.getByType<ApplicationExtension>()
13+
configureAndroidCompose(extension)
14+
}
15+
}
16+
}
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
import com.android.build.api.dsl.ApplicationExtension
2+
import com.moneymong.moneymong.buildlogic.convention.configureKotlinAndroid
3+
import org.gradle.api.Plugin
4+
import org.gradle.api.Project
5+
import org.gradle.kotlin.dsl.configure
6+
7+
class AndroidApplicationConventionPlugin : Plugin<Project> {
8+
override fun apply(target: Project) {
9+
with(target) {
10+
with(pluginManager) {
11+
apply("com.android.application")
12+
apply("org.jetbrains.kotlin.android")
13+
}
14+
15+
extensions.configure<ApplicationExtension> {
16+
configureKotlinAndroid(this)
17+
defaultConfig.targetSdk = 34
18+
}
19+
}
20+
}
21+
}
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
import com.android.build.api.dsl.ApplicationExtension
2+
import com.moneymong.moneymong.buildlogic.convention.configureFlavors
3+
import org.gradle.api.Plugin
4+
import org.gradle.api.Project
5+
import org.gradle.kotlin.dsl.configure
6+
7+
class AndroidApplicationFlavorsConventionPlugin : Plugin<Project> {
8+
override fun apply(target: Project) {
9+
with(target) {
10+
extensions.configure<ApplicationExtension> {
11+
configureFlavors(this)
12+
}
13+
}
14+
}
15+
}

0 commit comments

Comments
 (0)