KotlinWithGradleConfigurator: support addKotlinLibraryToModuleBuildScript for multiplatform

#KT-27270 Fixed
This commit is contained in:
Dmitry Gridin
2019-07-17 18:01:32 +03:00
parent c88d4f43d3
commit 645bbc93cb
26 changed files with 507 additions and 35 deletions
@@ -12,5 +12,5 @@ apply plugin: 'kotlin'
dependencies {
compile "org.jetbrains.kotlin:kotlin-stdlib-1.1.0"
compile "org.jetbrains.kotlin:kotlin-reflect:1.0.0"
}
implementation "org.jetbrains.kotlin:kotlin-reflect:1.0.0"
}
@@ -5,5 +5,5 @@ plugins {
dependencies {
testCompile("junit:junit:4.12")
compile(kotlinModule("stdlib-jre8"))
compile(kotlinModule("reflect", "1.0.0"))
implementation(kotlinModule("reflect", "1.0.0"))
}
@@ -5,5 +5,5 @@ plugins {
dependencies {
testCompile("junit:junit:4.12")
compile(kotlinModule("stdlib-jre8"))
compile(kotlin("reflect"))
implementation(kotlin("reflect"))
}
@@ -7,5 +7,5 @@ val kotlin_version: String by extra
dependencies {
testCompile("junit:junit:4.12")
compile(kotlinModule("stdlib-jre8", kotlin_version))
compile(kotlinModule("reflect", kotlin_version))
implementation(kotlinModule("reflect", kotlin_version))
}
@@ -0,0 +1,58 @@
plugins {
id 'org.jetbrains.kotlin.multiplatform' version '1.3.41'
}
repositories {
mavenCentral()
}
group 'com.example'
version '0.0.1'
apply plugin: 'kotlin-multiplatform'
kotlin {
jvm()
js()
sourceSets {
commonMain {
dependencies {
implementation kotlin('stdlib-common')
}
}
commonTest {
dependencies {
implementation kotlin('test-common')
implementation kotlin('test-annotations-common')
}
}
project {
dependencies {
implementation kotlin('stdlib-jdk8')
}
}
plainJvm {
dependencies {
jvm()
implementation kotlin('stdlib-jdk8')
}
}
jvmTest {
dependencies {
implementation kotlin('test')
implementation kotlin('test-junit')
}
}
jsMain {
dependencies {
implementation kotlin('stdlib-js')
}
}
jsTest {
dependencies {
implementation kotlin('test-js')
}
}
}
}
@@ -0,0 +1,63 @@
plugins {
id 'org.jetbrains.kotlin.multiplatform' version '1.3.41'
}
repositories {
mavenCentral()
}
group 'com.example'
version '0.0.1'
apply plugin: 'kotlin-multiplatform'
kotlin {
jvm()
js()
sourceSets {
commonMain {
dependencies {
implementation kotlin('stdlib-common')
}
}
commonTest {
dependencies {
implementation kotlin('test-common')
implementation kotlin('test-annotations-common')
}
}
project {
dependencies {
implementation kotlin('stdlib-jdk8')
}
}
plainJvm {
dependencies {
jvm()
implementation kotlin('stdlib-jdk8')
}
}
jvmTest {
dependencies {
implementation kotlin('test')
implementation kotlin('test-junit')
}
}
jsMain {
dependencies {
implementation kotlin('stdlib-js')
}
}
jsTest {
dependencies {
implementation kotlin('test-js')
}
}
jvmMain {
dependencies {
implementation "org.jetbrains.kotlin:kotlin-reflect:1.3.50"
}
}
}
}
@@ -0,0 +1,21 @@
plugins {
kotlin("multiplatform") version "1.3.41"
}
repositories {
mavenCentral()
}
group = "com.example"
version = "0.0.1"
kotlin {
sourceSets {
jvm()
val commonMain by getting {
dependencies {
implementation(kotlin("reflect"))
}
}
}
}
@@ -0,0 +1,26 @@
plugins {
kotlin("multiplatform") version "1.3.41"
}
repositories {
mavenCentral()
}
group = "com.example"
version = "0.0.1"
kotlin {
sourceSets {
jvm()
val commonMain by getting {
dependencies {
implementation(kotlin("reflect"))
}
}
getByName("jvmMain") {
dependencies {
implementation(kotlin("reflect"))
}
}
}
}
@@ -0,0 +1,23 @@
plugins {
kotlin("multiplatform") version "1.3.41"
}
repositories {
mavenCentral()
}
group = "com.example"
version = "0.0.1"
kotlin {
sourceSets {
jvm()
val commonMain by getting {
dependencies {
implementation(kotlin("reflect"))
}
}
getByName("jvmMain") {
}
}
}
@@ -0,0 +1,26 @@
plugins {
kotlin("multiplatform") version "1.3.41"
}
repositories {
mavenCentral()
}
group = "com.example"
version = "0.0.1"
kotlin {
sourceSets {
jvm()
val commonMain by getting {
dependencies {
implementation(kotlin("reflect"))
}
}
getByName("jvmMain") {
dependencies {
implementation(kotlin("reflect"))
}
}
}
}
@@ -0,0 +1,25 @@
plugins {
kotlin("multiplatform") version "1.3.41"
}
repositories {
mavenCentral()
}
group = "com.example"
version = "0.0.1"
kotlin {
sourceSets {
jvm()
val commonMain by getting {
dependencies {
implementation(kotlin("reflect"))
}
}
val jvmMain by getting {
dependencies {
}
}
}
}
@@ -0,0 +1,26 @@
plugins {
kotlin("multiplatform") version "1.3.41"
}
repositories {
mavenCentral()
}
group = "com.example"
version = "0.0.1"
kotlin {
sourceSets {
jvm()
val commonMain by getting {
dependencies {
implementation(kotlin("reflect"))
}
}
val jvmMain by getting {
dependencies {
implementation(kotlin("reflect"))
}
}
}
}
@@ -0,0 +1,22 @@
plugins {
kotlin("multiplatform") version "1.3.41"
}
repositories {
mavenCentral()
}
group = "com.example"
version = "0.0.1"
kotlin {
sourceSets {
jvm()
val commonMain by getting {
dependencies {
implementation(kotlin("reflect"))
}
}
val jvmMain by getting
}
}
@@ -0,0 +1,26 @@
plugins {
kotlin("multiplatform") version "1.3.41"
}
repositories {
mavenCentral()
}
group = "com.example"
version = "0.0.1"
kotlin {
sourceSets {
jvm()
val commonMain by getting {
dependencies {
implementation(kotlin("reflect"))
}
}
val jvmMain by getting {
dependencies {
implementation(kotlin("reflect"))
}
}
}
}
@@ -0,0 +1,23 @@
plugins {
kotlin("multiplatform") version "1.3.41"
}
repositories {
mavenCentral()
}
group = "com.example"
version = "0.0.1"
kotlin {
sourceSets {
jvm()
val commonMain by getting {
dependencies {
implementation(kotlin("reflect"))
}
}
val jvmMain by getting {
}
}
}
@@ -0,0 +1,26 @@
plugins {
kotlin("multiplatform") version "1.3.41"
}
repositories {
mavenCentral()
}
group = "com.example"
version = "0.0.1"
kotlin {
sourceSets {
jvm()
val commonMain by getting {
dependencies {
implementation(kotlin("reflect"))
}
}
val jvmMain by getting {
dependencies {
implementation(kotlin("reflect"))
}
}
}
}
@@ -5,5 +5,5 @@ plugins {
dependencies {
testCompile("junit:junit:4.12")
compile(kotlinModule("stdlib-jre8"))
compile("org.a.b:lib:1.0.0")
implementation("org.a.b:lib:1.0.0")
}
@@ -4,6 +4,6 @@ plugins {
dependencies {
compile(kotlinModule("stdlib-jre8"))
testCompile("junit:junit:4.12")
testCompile(kotlinModule("test", "1.1.2"))
testImplementation("junit:junit:4.12")
testImplementation(kotlinModule("test", "1.1.2"))
}
@@ -4,6 +4,6 @@ plugins {
dependencies {
compile(kotlinModule("stdlib-jre8"))
testCompile("junit:junit:4.12")
testCompile(kotlin("test"))
testImplementation("junit:junit:4.12")
testImplementation(kotlin("test"))
}
@@ -18,5 +18,5 @@ repositories {
}
dependencies {
compile "org.jetbrains.kotlin:kotlin-stdlib:1.1.0"
compile "org.jetbrains.kotlin:kotlin-reflect:1.1.0"
implementation "org.jetbrains.kotlin:kotlin-reflect:1.1.0"
}