Skip to content

Commit

Permalink
Update Compose version to BOM 2023.01.00
Browse files Browse the repository at this point in the history
  • Loading branch information
mr0xf00 committed Feb 5, 2023
1 parent fa843b6 commit a223d1e
Show file tree
Hide file tree
Showing 5 changed files with 36 additions and 52 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,10 @@ Add a dependency on the library to your Android project (Desktop not supported f

```kotlin
dependencies {
implementation("io.github.mr0xf00:easycrop:0.1.0")
implementation("io.github.mr0xf00:easycrop:0.1.1")
}
```
#### 2. Create an `ImageCropper` an instance
#### 2. Create an `ImageCropper` instance
#### ***Option 1 : inside the composition***
```kotlin
val imageCropper = rememberImageCropper()
Expand Down
8 changes: 1 addition & 7 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,11 +1,5 @@
buildscript {
ext {
compose_ui_version = '1.2.1'
compose_compiler_version = '1.3.0'
}
}
plugins {
id 'com.android.application' version '7.3.1' apply false
id 'com.android.library' version '7.3.1' apply false
id 'org.jetbrains.kotlin.android' version '1.7.10' apply false
id 'org.jetbrains.kotlin.android' version '1.8.0' apply false
}
20 changes: 10 additions & 10 deletions easycrop/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ plugins {
id("signing")
}

val compose_compiler_version : String by rootProject.extra
val compose_ui_version : String by rootProject.extra
val composeBomVersion : String by project
val composeCompilerVersion : String by project

android {
namespace = "com.mr0xf00.easycrop"
Expand All @@ -19,7 +19,7 @@ android {
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
}
composeOptions {
kotlinCompilerExtensionVersion = compose_compiler_version
kotlinCompilerExtensionVersion = composeCompilerVersion
}
buildFeatures {
compose = true
Expand All @@ -40,15 +40,15 @@ android {
}

dependencies {
implementation(platform("androidx.compose:compose-bom:$composeBomVersion"))
implementation ("androidx.core:core-ktx:1.9.0")
testImplementation ("junit:junit:4.13.2")
androidTestImplementation ("androidx.test.ext:junit:1.1.3")
androidTestImplementation ("androidx.test.espresso:espresso-core:3.4.0")
androidTestImplementation ("androidx.test.ext:junit:1.1.5")
implementation ("androidx.lifecycle:lifecycle-runtime-ktx:2.5.1")
implementation ("androidx.activity:activity-compose:1.6.0")
implementation ("androidx.compose.material:material:$compose_ui_version")
implementation ("androidx.compose.ui:ui:$compose_ui_version")
implementation ("org.jetbrains.kotlinx:kotlinx-coroutines-test:1.6.4")
implementation ("androidx.activity:activity-compose:1.6.1")
implementation ("androidx.compose.material:material")
implementation ("androidx.compose.ui:ui")
androidTestImplementation ("org.jetbrains.kotlinx:kotlinx-coroutines-test:1.6.4")
}

fun extProperty(key: String): String {
Expand All @@ -59,7 +59,7 @@ publishing {
val data = object {
val groupId = "io.github.mr0xf00"
val artifactId = "easycrop"
val version = "0.1.0"
val version = "0.1.1"
private val releasesRepoUrl =
uri("https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/")
private val snapshotsRepoUrl =
Expand Down
24 changes: 4 additions & 20 deletions gradle.properties
Original file line number Diff line number Diff line change
@@ -1,23 +1,7 @@
# Project-wide Gradle settings.
# IDE (e.g. Android Studio) users:
# Gradle settings configured through the IDE *will override*
# any settings specified in this file.
# For more details on how to configure your build environment visit
# http://www.gradle.org/docs/current/userguide/build_environment.html
# Specifies the JVM arguments used for the daemon process.
# The setting is particularly useful for tweaking memory settings.
org.gradle.jvmargs=-Xmx2048m -Dfile.encoding=UTF-8
# When configured, Gradle will run in incubating parallel mode.
# This option should only be used with decoupled projects. More details, visit
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
# org.gradle.parallel=true
# AndroidX package structure to make it clearer which packages are bundled with the
# Android operating system, and which are packaged with your app's APK
# https://developer.android.com/topic/libraries/support-library/androidx-rn
android.useAndroidX=true
# Kotlin code style for this project: "official" or "obsolete":
kotlin.code.style=official
# Enables namespacing of each library's R class so that its R class includes only the
# resources declared in the library itself and none from the library's dependencies,
# thereby reducing the size of the R class for that library
android.nonTransitiveRClass=true
android.nonTransitiveRClass=true

composeBomVersion=2023.01.00
composeCompilerVersion=1.4.0
32 changes: 19 additions & 13 deletions sample/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ plugins {
id 'org.jetbrains.kotlin.android'
}

def composeBomVersion = project.property('composeBomVersion')
def composeCompilerVersion = project.property('composeCompilerVersion')

android {
namespace 'com.mr0xf00.easycrop'
compileSdk 33
Expand Down Expand Up @@ -31,7 +34,7 @@ android {
targetCompatibility JavaVersion.VERSION_1_8
}
composeOptions {
kotlinCompilerExtensionVersion = "$compose_compiler_version"
kotlinCompilerExtensionVersion = composeCompilerVersion
}
buildFeatures {
compose = true
Expand All @@ -49,22 +52,25 @@ android {
}

dependencies {
def composeBom = platform("androidx.compose:compose-bom:$composeBomVersion")
implementation composeBom
androidTestImplementation composeBom

implementation 'androidx.core:core-ktx:1.9.0'
implementation 'androidx.lifecycle:lifecycle-runtime-ktx:2.5.1'
implementation 'androidx.activity:activity-compose:1.6.0'
implementation "androidx.compose.ui:ui:$compose_ui_version"
implementation "androidx.compose.ui:ui-tooling-preview:$compose_ui_version"
implementation 'androidx.compose.material:material:1.2.1'
implementation 'androidx.activity:activity-compose:1.6.1'
implementation "androidx.compose.ui:ui"
implementation "androidx.compose.ui:ui-tooling-preview"
implementation 'androidx.compose.material:material'
testImplementation 'junit:junit:4.13.2'
androidTestImplementation 'androidx.test.ext:junit:1.1.3'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.4.0'
androidTestImplementation "androidx.compose.ui:ui-test-junit4:$compose_ui_version"
debugImplementation "androidx.compose.ui:ui-tooling:$compose_ui_version"
debugImplementation "androidx.compose.ui:ui-test-manifest:$compose_ui_version"
androidTestImplementation 'androidx.test.ext:junit:1.1.5'
androidTestImplementation "androidx.compose.ui:ui-test-junit4"
debugImplementation "androidx.compose.ui:ui-tooling"
debugImplementation "androidx.compose.ui:ui-test-manifest"
implementation ("androidx.core:core-ktx:1.9.0")
implementation ("androidx.lifecycle:lifecycle-runtime-ktx:2.5.1")
implementation ("androidx.activity:activity-compose:1.6.0")
implementation ("androidx.compose.ui:ui:$compose_ui_version")
implementation ("androidx.compose.material:material:1.2.1")
implementation ("androidx.activity:activity-compose:1.6.1")
implementation ("androidx.compose.ui:ui")
implementation ("androidx.compose.material:material")
implementation(project(":easycrop"))
}

0 comments on commit a223d1e

Please sign in to comment.