Skip to content

Commit b76722d

Browse files
committed
refactor gradle
1 parent 3816aa7 commit b76722d

File tree

8 files changed

+17
-36
lines changed

8 files changed

+17
-36
lines changed

core/common_shared/build.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ kotlin {
2323
vendor.set(JvmVendorSpec.AZUL)
2424
}
2525

26-
targetHierarchy.default()
26+
applyDefaultHierarchyTemplate()
2727

2828
jvm()
2929

core/common_ui_shared/build.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ kotlin {
3030
vendor.set(JvmVendorSpec.AZUL)
3131
}
3232

33-
targetHierarchy.default()
33+
applyDefaultHierarchyTemplate()
3434

3535
jvm()
3636

core/navigation_shared/build.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ kotlin {
2525
vendor.set(JvmVendorSpec.AZUL)
2626
}
2727

28-
targetHierarchy.default()
28+
applyDefaultHierarchyTemplate()
2929

3030
androidTarget {
3131
compilations.all {

features/feature_search_photo_shared/build.gradle.kts

Lines changed: 10 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -40,20 +40,10 @@ kotlin {
4040
iosArm64()
4141
iosSimulatorArm64()
4242

43-
// cocoapods {
44-
// version = "1.0.0"
45-
// summary = "Some description for the Shared Module"
46-
// homepage = "Link to the Shared Module homepage"
47-
// ios.deploymentTarget = "14.1"
48-
// podfile = project.file("../iosApp/Podfile")
49-
// framework {
50-
// baseName = "shared"
51-
// isStatic = true
52-
// }
53-
// }
43+
applyDefaultHierarchyTemplate()
5444

5545
sourceSets {
56-
val commonMain by getting {
46+
commonMain {
5747
kotlin.srcDir("build/generated/ksp/metadata/commonMain/kotlin")
5848

5949
dependencies {
@@ -127,7 +117,7 @@ kotlin {
127117
api(libs.napier)
128118
}
129119
}
130-
val androidMain by getting {
120+
androidMain {
131121
dependencies {
132122
api(libs.androidx.activity.compose)
133123
api(libs.androidx.appcompat)
@@ -140,15 +130,7 @@ kotlin {
140130
implementation(libs.kotlinx.coroutines.android)
141131
}
142132
}
143-
val iosX64Main by getting
144-
val iosArm64Main by getting
145-
val iosSimulatorArm64Main by getting
146-
val iosMain by creating {
147-
dependsOn(commonMain)
148-
iosX64Main.dependsOn(this)
149-
iosArm64Main.dependsOn(this)
150-
iosSimulatorArm64Main.dependsOn(this)
151-
133+
iosMain {
152134
dependencies {
153135
// Ktor
154136
implementation(libs.ktor.client.darwin)
@@ -242,13 +224,12 @@ buildkonfig {
242224
buildConfigField(
243225
type = FieldSpec.Type.STRING,
244226
name = "UNSPLASH_CLIENT_ID",
245-
value =
246-
if (isCiBuild) {
247-
logger.info("CI build, ignore checking existence of local.properties file")
248-
"none"
249-
} else {
250-
rootProject.readPropertiesFile("local.properties")["UNSPLASH_CLIENT_ID_DEV"]
251-
},
227+
value = if (isCiBuild) {
228+
logger.info("CI build, ignore checking existence of local.properties file")
229+
"none"
230+
} else {
231+
rootProject.readPropertiesFile("local.properties")["UNSPLASH_CLIENT_ID_DEV"]
232+
},
252233
)
253234
buildConfigField(
254235
type = FieldSpec.Type.STRING,

libraries/compose-stable-wrappers/build.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ kotlin {
2323
vendor.set(JvmVendorSpec.AZUL)
2424
}
2525

26-
targetHierarchy.default()
26+
applyDefaultHierarchyTemplate()
2727

2828
jvm()
2929

libraries/coroutines-utils/build.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ kotlin {
2323
vendor.set(JvmVendorSpec.AZUL)
2424
}
2525

26-
targetHierarchy.default()
26+
applyDefaultHierarchyTemplate()
2727

2828
jvm()
2929

libraries/koin-compose-utils/build.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ kotlin {
3030
vendor.set(JvmVendorSpec.AZUL)
3131
}
3232

33-
targetHierarchy.default()
33+
applyDefaultHierarchyTemplate()
3434

3535
jvm()
3636

libraries/koin-utils/build.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ kotlin {
2323
vendor.set(JvmVendorSpec.AZUL)
2424
}
2525

26-
targetHierarchy.default()
26+
applyDefaultHierarchyTemplate()
2727

2828
jvm()
2929

0 commit comments

Comments
 (0)