Skip to content

Commit 4442007

Browse files
committed
Update to 1.2.15
1 parent 1c871ba commit 4442007

File tree

8 files changed

+46
-48
lines changed

8 files changed

+46
-48
lines changed

.github/workflows/build.yml

+7-7
Original file line numberDiff line numberDiff line change
@@ -28,11 +28,11 @@ jobs:
2828
- name: Validate Gradle Wrapper
2929
uses: gradle/wrapper-validation-action@v3
3030

31-
- name: Set up JDK 17
31+
- name: Set up JDK 21
3232
uses: actions/setup-java@v4
3333
with:
3434
distribution: 'zulu'
35-
java-version: 17
35+
java-version: 21
3636

3737
- name: Setup Gradle
3838
uses: gradle/actions/setup-gradle@v4
@@ -64,24 +64,24 @@ jobs:
6464
if: steps.avd-cache.outputs.cache-hit != 'true'
6565
uses: reactivecircus/android-emulator-runner@v2
6666
with:
67-
api-level: 34
67+
api-level: 35
6868
target: google_apis
6969
arch: x86_64
7070
profile: pixel_6
71-
emulator-build: 12265550
71+
emulator-build: 12694320
7272
force-avd-creation: false
7373
emulator-options: -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none
7474
disable-animations: true
7575
script: echo "Generated AVD snapshot for caching."
7676

77-
- name: Run Android 14 Instrumented Tests
77+
- name: Run Android 15 Instrumented Tests
7878
uses: reactivecircus/android-emulator-runner@v2
7979
with:
80-
api-level: 34
80+
api-level: 35
8181
target: google_apis
8282
arch: x86_64
8383
profile: pixel_6
84-
emulator-build: 12265550
84+
emulator-build: 12694320
8585
force-avd-creation: false
8686
emulator-options: -no-snapshot-save -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none
8787
disable-animations: true

.github/workflows/publish.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,11 @@ jobs:
2323
- name: Validate Gradle Wrapper
2424
uses: gradle/wrapper-validation-action@v3
2525

26-
- name: Set up JDK 17
26+
- name: Set up JDK 21
2727
uses: actions/setup-java@v4
2828
with:
2929
distribution: 'zulu'
30-
java-version: 17
30+
java-version: 21
3131

3232
- name: Setup Gradle
3333
uses: gradle/actions/setup-gradle@v4

README.md

+6-6
Original file line numberDiff line numberDiff line change
@@ -12,17 +12,17 @@ Kotlin Multiplatform Common (kts):
1212

1313
```kotlin
1414
dependencies {
15-
implementation("com.ctrip.flight.mmkv:mmkv-kotlin:1.2.14")
15+
implementation("com.ctrip.flight.mmkv:mmkv-kotlin:1.2.15")
1616
}
1717
```
1818

19-
Current version is based on `Kotlin 2.0.20` and `MMKV 1.3.9`.
19+
Current version is based on `Kotlin 2.1.0` and `MMKV 2.0.1`.
2020

2121
Pure Android platform (kts):
2222

2323
```kotlin
2424
dependencies {
25-
implementation("com.ctrip.flight.mmkv:mmkv-kotlin-android:1.2.14")
25+
implementation("com.ctrip.flight.mmkv:mmkv-kotlin-android:1.2.15")
2626
}
2727
```
2828

@@ -31,10 +31,10 @@ Kotlin/Native on macOS:
3131
```kotlin
3232
dependencies {
3333
// Intel Chip
34-
implementation("com.ctrip.flight.mmkv:mmkv-kotlin-macosx64:1.2.14")
34+
implementation("com.ctrip.flight.mmkv:mmkv-kotlin-macosx64:1.2.15")
3535

3636
// M1&M2 Chip
37-
implementation("com.ctrip.flight.mmkv:mmkv-kotlin-macosarm64:1.2.14")
37+
implementation("com.ctrip.flight.mmkv:mmkv-kotlin-macosarm64:1.2.15")
3838
}
3939
```
4040
Note, if your project is a Kotlin/Native executable program project of macOS, or it supplies a framework to an iOS application project directly, then you need to manually add the dependency of MMKV, and may need to add `linkerOpts` for MMKV and MMKVCore:
@@ -62,7 +62,7 @@ kotlin {
6262
cocoapods {
6363
// ......
6464
pod(name = "MMKV") {
65-
version = "1.3.9"
65+
version = "2.0.1"
6666
moduleName = "MMKV"
6767
}
6868
}

README_CN.md

+6-6
Original file line numberDiff line numberDiff line change
@@ -10,17 +10,17 @@ Kotlin Multiplatform Common (kts):
1010

1111
```kotlin
1212
dependencies {
13-
implementation("com.ctrip.flight.mmkv:mmkv-kotlin:1.2.14")
13+
implementation("com.ctrip.flight.mmkv:mmkv-kotlin:1.2.15")
1414
}
1515
```
1616

17-
当前版本依赖于 `Kotlin 2.0.20` 以及 `MMKV 1.3.9`
17+
当前版本依赖于 `Kotlin 2.1.0` 以及 `MMKV 2.0.1`
1818

1919
纯 Android 平台(kts):
2020

2121
```kotlin
2222
dependencies {
23-
implementation("com.ctrip.flight.mmkv:mmkv-kotlin-android:1.2.14")
23+
implementation("com.ctrip.flight.mmkv:mmkv-kotlin-android:1.2.15")
2424
}
2525
```
2626

@@ -29,10 +29,10 @@ Kotlin/Native on macOS:
2929
```kotlin
3030
dependencies {
3131
// Intel 芯片
32-
implementation("com.ctrip.flight.mmkv:mmkv-kotlin-macosx64:1.2.14")
32+
implementation("com.ctrip.flight.mmkv:mmkv-kotlin-macosx64:1.2.15")
3333

3434
// M1&M2 芯片
35-
implementation("com.ctrip.flight.mmkv:mmkv-kotlin-macosarm64:1.2.14")
35+
implementation("com.ctrip.flight.mmkv:mmkv-kotlin-macosarm64:1.2.15")
3636
}
3737
```
3838
注意,如果你的工程为 macOS 的 Kotlin/Native 可执行程序工程,或者它直接向一个 iOS 应用程序工程提供 framework,那么您需要手动在工程中添加对 MMKV 的依赖,并可能需要添加对 MMKV 及 MMKVCore 的 `linkerOpts`
@@ -60,7 +60,7 @@ kotlin {
6060
cocoapods {
6161
// ......
6262
pod(name = "MMKV") {
63-
version = "1.3.9"
63+
version = "2.0.1"
6464
moduleName = "MMKV"
6565
}
6666
}

gradle/libs.versions.toml

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
[versions]
22

3-
kotlin = "2.0.20"
4-
agp = "8.6.0"
5-
mmkv = "1.3.9"
3+
kotlin = "2.1.0"
4+
agp = "8.7.3"
5+
mmkv = "2.0.1"
66
junit = "4.13.2"
77
androidx-test = "1.6.1"
88
androidx-test-runner = "1.6.2"

mmkv-kotlin/MMKV_Kotlin.podspec

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Pod::Spec.new do |spec|
22
spec.name = 'mmkv_kotlin'
3-
spec.version = '1.2.14'
3+
spec.version = '1.2.15'
44
spec.homepage = 'Link to the Shared Module homepage'
55
spec.source = { :http=> ''}
66
spec.authors = ''
@@ -10,7 +10,7 @@ Pod::Spec.new do |spec|
1010
spec.libraries = 'c++'
1111
spec.ios.deployment_target = '17.5.1'
1212
spec.osx.deployment_target = '14.4.1'
13-
spec.dependency 'MMKV', '1.3.9'
13+
spec.dependency 'MMKV', '2.0.1'
1414

1515
if !Dir.exist?('build/cocoapods/framework/MMKV_Kotlin.framework') || Dir.empty?('build/cocoapods/framework/MMKV_Kotlin.framework')
1616
raise "

mmkv-kotlin/build.gradle.kts

+15-21
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ plugins {
1010
signing
1111
}
1212

13-
version = "1.2.14"
13+
version = "1.2.15"
1414
group = "com.ctrip.flight.mmkv"
1515

1616
@OptIn(ExperimentalKotlinGradlePluginApi::class)
@@ -32,8 +32,8 @@ kotlin {
3232
cocoapods {
3333
summary = "Some description for the Shared Module"
3434
homepage = "Link to the Shared Module homepage"
35-
ios.deploymentTarget = "17.5.1"
36-
osx.deploymentTarget = "14.4.1"
35+
ios.deploymentTarget = "18.1.1"
36+
osx.deploymentTarget = "15.1.1"
3737
framework {
3838
baseName = "MMKV-Kotlin"
3939
isStatic = true
@@ -48,38 +48,32 @@ kotlin {
4848
all {
4949
languageSettings.optIn("kotlin.RequiresOptIn")
5050
}
51-
val commonTest by getting {
52-
dependencies {
53-
implementation(kotlin("test"))
54-
}
51+
commonTest.dependencies {
52+
implementation(kotlin("test"))
5553
}
56-
val androidMain by getting {
57-
dependencies {
58-
api(libs.mmkv)
59-
}
54+
androidMain.dependencies {
55+
api(libs.mmkv)
6056
}
61-
val androidInstrumentedTest by getting {
62-
dependencies {
63-
implementation(kotlin("test-junit"))
64-
implementation(libs.junit)
65-
implementation(libs.androidx.test.core)
66-
implementation(libs.androidx.test.runner)
67-
implementation(libs.androidx.test.rules)
68-
}
57+
androidInstrumentedTest.dependencies {
58+
implementation(kotlin("test-junit"))
59+
implementation(libs.junit)
60+
implementation(libs.androidx.test.core)
61+
implementation(libs.androidx.test.runner)
62+
implementation(libs.androidx.test.rules)
6963
}
7064
}
7165
}
7266

7367
android {
7468
namespace = "com.ctrip.flight.mmkv"
75-
compileSdk = 34
69+
compileSdk = 35
7670
defaultConfig {
7771
minSdk = 23
7872
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
7973
}
8074
compileOptions {
8175
sourceCompatibility = JavaVersion.VERSION_11
82-
targetCompatibility = JavaVersion.VERSION_17
76+
targetCompatibility = JavaVersion.VERSION_21
8377
}
8478
}
8579

mmkv-kotlin/src/commonMain/kotlin/com/ctrip/flight/mmkv/Util.kt

+5-1
Original file line numberDiff line numberDiff line change
@@ -30,4 +30,8 @@ expect fun setLogLevel(logLevel: MMKVLogLevel)
3030

3131
expect fun version(): String
3232

33-
expect fun unregisterHandler()
33+
expect fun unregisterHandler()
34+
35+
36+
37+
expect fun log(msg: String)

0 commit comments

Comments
 (0)