Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 8 additions & 21 deletions android/build.gradle
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
buildscript {
def kotlin_version = rootProject.ext.has("kotlinVersion") ? rootProject.ext.get("kotlinVersion") : "1.9.24"
def kotlin_version = rootProject.ext.has("kotlinVersion") ? rootProject.ext.get("kotlinVersion") : "2.1.20"

repositories {
google()
Expand All @@ -13,10 +13,6 @@ buildscript {
}
}

def isNewArchitectureEnabled() {
return rootProject.hasProperty("newArchEnabled") && rootProject.getProperty("newArchEnabled") == "true"
}

def safeExtGet(prop, fallback) {
rootProject.ext.has(prop) ? rootProject.ext.get(prop) : fallback
}
Expand All @@ -26,34 +22,25 @@ apply plugin: "com.facebook.react"
apply plugin: "kotlin-android"

android {
compileSdkVersion safeExtGet("compileSdkVersion", 35)
namespace "com.xmartlabs.line"
compileSdk safeExtGet("compileSdkVersion", 36)

defaultConfig {
minSdkVersion safeExtGet("minSdkVersion", 24)
targetSdkVersion safeExtGet("targetSdkVersion", 35)
minSdk safeExtGet("minSdkVersion", 24)
targetSdk safeExtGet("targetSdkVersion", 36)
versionCode 1
versionName "5.6.0"
}

sourceSets {
main {
java.srcDirs += ["${project.buildDir}/generated/source/codegen/java"]
java.srcDirs += ["${layout.buildDirectory.get().asFile}/generated/source/codegen/java"]
}
}
}

dependencies {
implementation "com.facebook.react:react-native:+"
implementation "com.linecorp.linesdk:linesdk:5.11.0"
implementation "org.jetbrains.kotlinx:kotlinx-coroutines-android:1.7.3"
implementation "com.linecorp.linesdk:linesdk:5.12.0"
implementation "org.jetbrains.kotlinx:kotlinx-coroutines-android:1.10.2"
}

tasks.register("checkNativeLineLoginSpec") {
doLast {
if (!isNewArchitectureEnabled()) {
throw new GradleException("@xmartlabs/react-native-line v5 requires your project to have NEW ARCHITECTURE ENABLED. Use v4 if you want to keep using the old architecture.")
}
}
}

preBuild.dependsOn checkNativeLineLoginSpec
3 changes: 1 addition & 2 deletions android/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -1,2 +1 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.xmartlabs.line"></manifest>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" />
Loading