Skip to content

Instantly share code, notes, and snippets.

@iseki0
Created May 22, 2020 15:32
Show Gist options
  • Save iseki0/1833f329d38e052bfaa098086626179e to your computer and use it in GitHub Desktop.
Save iseki0/1833f329d38e052bfaa098086626179e to your computer and use it in GitHub Desktop.
plugins {
java
kotlin("jvm") version "1.4-M1"
application
}
group = "space.iseki"
version = "1.0-SNAPSHOT"
repositories {
if (System.getenv("GITHUB_WORKFLOW").orEmpty().trim().isBlank()) {
maven("https://maven.aliyun.com/repository/public")
println("add aliyun repos")
} else {
println("detected Github Action, not add aliyun repos.")
}
maven("https://dl.bintray.com/kotlin/kotlin-eap")
mavenCentral()
}
dependencies {
implementation(kotlin("stdlib-jdk8"))
// testImplementation("junit", "junit", "4.12")
testImplementation("org.junit.jupiter:junit-jupiter-api:5.6.2")
testImplementation("org.junit.jupiter:junit-jupiter:5.6.2")
implementation("com.atlassian.commonmark:commonmark:0.15.0")
}
configure<JavaPluginConvention> {
sourceCompatibility = JavaVersion.VERSION_1_8
}
tasks {
compileKotlin {
kotlinOptions.jvmTarget = "1.8"
}
compileTestKotlin {
kotlinOptions.jvmTarget = "1.8"
}
}
application {
mainClassName = "space.iseki.i.MainKt"
}
tasks.test {
useJUnitPlatform()
testLogging {
events("passed", "skipped", "failed")
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment