-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Migrated rest of module build.gradle to kts
- Loading branch information
1 parent
8e2b8be
commit 3cf727f
Showing
30 changed files
with
823 additions
and
744 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,75 @@ | ||
plugins { | ||
id("com.android.library") | ||
id("kotlin-android") | ||
} | ||
|
||
apply { | ||
from("$rootDir/.buildscript/configure-signing.gradle") | ||
from("$rootDir/.buildscript/jacoco-workaround.gradle") | ||
} | ||
|
||
android { | ||
compileSdk = libs.versions.compileSdk.get().toInt() | ||
|
||
defaultConfig { | ||
minSdk = libs.versions.minSdk.get().toInt() | ||
targetSdk = libs.versions.targetSdk.get().toInt() | ||
} | ||
|
||
buildFeatures { | ||
compose = true | ||
} | ||
|
||
compileOptions { | ||
sourceCompatibility = JavaVersion.VERSION_1_8 | ||
targetCompatibility = JavaVersion.VERSION_1_8 | ||
} | ||
|
||
composeOptions { | ||
kotlinCompilerVersion = libs.versions.kotlin.get() | ||
kotlinCompilerExtensionVersion = libs.versions.compose.get() | ||
} | ||
} | ||
|
||
tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile>().all { | ||
kotlinOptions { | ||
jvmTarget = "1.8" | ||
} | ||
} | ||
|
||
task<Jar>("sourcesJar") { | ||
from(android.sourceSets["main"].java.srcDirs) | ||
archiveClassifier.set("sources") | ||
} | ||
|
||
task<Javadoc>("javadoc") { | ||
isFailOnError = false | ||
source(android.sourceSets["main"].java.getSourceFiles()) | ||
classpath += project.files(android.bootClasspath.joinToString(separator = File.pathSeparator)) | ||
classpath += configurations.api | ||
classpath += configurations.implementation | ||
} | ||
|
||
task<Jar>("javadocJar") { | ||
dependsOn("javadoc") | ||
archiveClassifier.set("javadoc") | ||
from(tasks["javadoc"].path) | ||
} | ||
|
||
artifacts { | ||
archives(tasks["sourcesJar"]) | ||
archives(tasks["javadocJar"]) | ||
} | ||
|
||
dependencies { | ||
api(project(":formula-android")) | ||
api(libs.compose.ui) | ||
|
||
implementation(libs.compose.rxjava3) | ||
|
||
testImplementation(libs.androidx.test.rules) | ||
testImplementation(libs.androidx.test.runner) | ||
testImplementation(libs.espresso.core) | ||
testImplementation(libs.truth) | ||
testImplementation(libs.kotlin.reflect) | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
plugins { | ||
id("com.android.application") | ||
id("kotlin-android") | ||
id("kotlin-parcelize") | ||
} | ||
|
||
apply { | ||
from("$rootDir/.buildscript/jacoco-workaround.gradle") | ||
} | ||
|
||
android { | ||
compileSdk = 28 | ||
defaultConfig { | ||
applicationId = "com.instacart.formula.samples" | ||
minSdk = libs.versions.minSdk.get().toInt() | ||
targetSdk = 28 // Using sdk 28 for robolectric tests. | ||
versionCode = 1 | ||
versionName = "1.0" | ||
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner" | ||
} | ||
|
||
compileOptions { | ||
sourceCompatibility = JavaVersion.VERSION_1_8 | ||
targetCompatibility = JavaVersion.VERSION_1_8 | ||
} | ||
|
||
buildTypes { | ||
release { | ||
isMinifyEnabled = false | ||
proguardFiles(getDefaultProguardFile("proguard-android-optimize.txt"), "proguard-rules.pro") | ||
} | ||
} | ||
|
||
testOptions { | ||
unitTests { | ||
isIncludeAndroidResources = true | ||
} | ||
} | ||
} | ||
|
||
tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile>().all { | ||
kotlinOptions { | ||
jvmTarget = "1.8" | ||
} | ||
} | ||
|
||
dependencies { | ||
implementation(project(":formula-rxjava3")) | ||
implementation(project(":formula-android")) | ||
|
||
implementation(libs.kotlin) | ||
implementation(libs.androidx.appcompat) | ||
implementation(libs.lifecycle.extensions) | ||
|
||
testImplementation(libs.junit) | ||
testImplementation(libs.truth) | ||
testImplementation(libs.androidx.test.rules) | ||
testImplementation(libs.androidx.test.runner) | ||
testImplementation(libs.espresso.core) | ||
testImplementation(libs.robolectric) | ||
} |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.