Wizard: add mpp mobile library template
This commit is contained in:
+61
@@ -0,0 +1,61 @@
|
||||
plugins {
|
||||
id 'org.jetbrains.kotlin.multiplatform' version '1.3.70'
|
||||
id 'com.android.application'
|
||||
id 'kotlin-android-extensions'
|
||||
}
|
||||
group = 'me.user'
|
||||
version = '1.0-SNAPSHOT'
|
||||
|
||||
repositories {
|
||||
gradlePluginPortal()
|
||||
google()
|
||||
jcenter()
|
||||
mavenCentral()
|
||||
}
|
||||
kotlin {
|
||||
android()
|
||||
iosX64('ios')
|
||||
sourceSets {
|
||||
commonMain {
|
||||
dependencies {
|
||||
implementation kotlin('stdlib-common')
|
||||
}
|
||||
}
|
||||
commonTest {
|
||||
dependencies {
|
||||
implementation kotlin('test-common')
|
||||
implementation kotlin('test-annotations-common')
|
||||
}
|
||||
}
|
||||
androidMain {
|
||||
dependencies {
|
||||
implementation kotlin('stdlib-jdk7')
|
||||
implementation 'androidx.core:core-ktx:1.1.0'
|
||||
}
|
||||
}
|
||||
androidTest {
|
||||
|
||||
}
|
||||
iosMain {
|
||||
|
||||
}
|
||||
iosTest {
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
android {
|
||||
compileSdkVersion 29
|
||||
defaultConfig {
|
||||
applicationId 'me.user.android'
|
||||
minSdkVersion 24
|
||||
targetSdkVersion 29
|
||||
versionCode 1
|
||||
versionName '1.0'
|
||||
}
|
||||
buildTypes {
|
||||
'release' {
|
||||
minifyEnabled false
|
||||
}
|
||||
}
|
||||
}
|
||||
+55
@@ -0,0 +1,55 @@
|
||||
plugins {
|
||||
kotlin("multiplatform") version "1.3.70"
|
||||
id("com.android.application")
|
||||
id("kotlin-android-extensions")
|
||||
}
|
||||
group = "me.user"
|
||||
version = "1.0-SNAPSHOT"
|
||||
|
||||
repositories {
|
||||
gradlePluginPortal()
|
||||
google()
|
||||
jcenter()
|
||||
mavenCentral()
|
||||
}
|
||||
kotlin {
|
||||
android()
|
||||
iosX64("ios")
|
||||
sourceSets {
|
||||
val commonMain by getting {
|
||||
dependencies {
|
||||
implementation(kotlin("stdlib-common"))
|
||||
}
|
||||
}
|
||||
val commonTest by getting {
|
||||
dependencies {
|
||||
implementation(kotlin("test-common"))
|
||||
implementation(kotlin("test-annotations-common"))
|
||||
}
|
||||
}
|
||||
val androidMain by getting {
|
||||
dependencies {
|
||||
implementation(kotlin("stdlib-jdk7"))
|
||||
implementation("androidx.core:core-ktx:1.1.0")
|
||||
}
|
||||
}
|
||||
val androidTest by getting
|
||||
val iosMain by getting
|
||||
val iosTest by getting
|
||||
}
|
||||
}
|
||||
android {
|
||||
compileSdkVersion(29)
|
||||
defaultConfig {
|
||||
applicationId = "me.user.android"
|
||||
minSdkVersion(24)
|
||||
targetSdkVersion(29)
|
||||
versionCode = 1
|
||||
versionName = "1.0"
|
||||
}
|
||||
buildTypes {
|
||||
getByName("release") {
|
||||
isMinifyEnabled = false
|
||||
}
|
||||
}
|
||||
}
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
pluginManagement {
|
||||
repositories {
|
||||
gradlePluginPortal()
|
||||
google()
|
||||
jcenter()
|
||||
}
|
||||
resolutionStrategy {
|
||||
eachPlugin {
|
||||
if (requested.id.namespace == 'com.android' || requested.id.name == 'kotlin-android-extensions') {
|
||||
useModule('com.android.tools.build:gradle:3.5.2')
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
rootProject.name = 'MultiplatformMobileLibrary'
|
||||
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
pluginManagement {
|
||||
repositories {
|
||||
gradlePluginPortal()
|
||||
google()
|
||||
jcenter()
|
||||
}
|
||||
resolutionStrategy {
|
||||
eachPlugin {
|
||||
if (requested.id.namespace == "com.android" || requested.id.name == "kotlin-android-extensions") {
|
||||
useModule("com.android.tools.build:gradle:3.5.2")
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
rootProject.name = "MultiplatformMobileLibrary"
|
||||
|
||||
+2
@@ -0,0 +1,2 @@
|
||||
android:
|
||||
androidSdkPath: android.sdk
|
||||
Reference in New Issue
Block a user