45 lines
807 B
Groovy
Vendored
45 lines
807 B
Groovy
Vendored
group 'Again'
|
|
version '1.0-SNAPSHOT'
|
|
|
|
buildscript {
|
|
repositories {
|
|
mavenCentral()
|
|
maven {
|
|
url 'https://dl.bintray.com/kotlin/kotlin-eap-1.1'
|
|
}
|
|
}
|
|
|
|
dependencies {
|
|
classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:1.1.0")
|
|
}
|
|
}
|
|
|
|
apply plugin: 'kotlin2js'
|
|
|
|
sourceSets {
|
|
myMain {
|
|
kotlin {
|
|
srcDir 'src'
|
|
}
|
|
}
|
|
myTest {
|
|
kotlin {
|
|
srcDir 'test'
|
|
}
|
|
}
|
|
}
|
|
|
|
dependencies {
|
|
compile "org.jetbrains.kotlin:kotlin-stdlib-js:1.1.0"
|
|
}
|
|
|
|
compileMyMainKotlin2Js {
|
|
kotlinOptions.sourceMap = true
|
|
kotlinOptions.freeCompilerArgs = ["-module-kind", "plain", "-main", "callMain"]
|
|
}
|
|
|
|
compileMyTestKotlin2Js {
|
|
kotlinOptions.apiVersion = "1.0"
|
|
kotlinOptions.freeCompilerArgs = ["-module-kind", "umd", "-main", "callTest"]
|
|
}
|