diff --git a/.idea/.name b/.idea/.name new file mode 100644 index 0000000..84459b0 --- /dev/null +++ b/.idea/.name @@ -0,0 +1 @@ +example-kotlin \ No newline at end of file diff --git a/.idea/misc.xml b/.idea/misc.xml index 99008eb..b4fe993 100644 --- a/.idea/misc.xml +++ b/.idea/misc.xml @@ -1,43 +1,5 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -60,7 +22,9 @@ - + + + diff --git a/.idea/modules/example-kotlin_main.iml b/.idea/modules/example-kotlin_main.iml index eb7fa6a..68dbc67 100644 --- a/.idea/modules/example-kotlin_main.iml +++ b/.idea/modules/example-kotlin_main.iml @@ -61,9 +61,6 @@ - - - @@ -73,7 +70,7 @@ - - + + \ No newline at end of file diff --git a/.idea/modules/example-kotlin_test.iml b/.idea/modules/example-kotlin_test.iml index 059cfd7..7dac6bc 100644 --- a/.idea/modules/example-kotlin_test.iml +++ b/.idea/modules/example-kotlin_test.iml @@ -62,7 +62,6 @@ - diff --git a/.idea/vcs.xml b/.idea/vcs.xml index 8306744..94a25f7 100644 --- a/.idea/vcs.xml +++ b/.idea/vcs.xml @@ -1,7 +1,6 @@ - \ No newline at end of file diff --git a/kobalt/src/Build.kt b/kobalt/src/Build.kt new file mode 100644 index 0000000..455eef2 --- /dev/null +++ b/kobalt/src/Build.kt @@ -0,0 +1,59 @@ +import com.beust.kobalt.* +import com.beust.kobalt.plugin.apt.* +import com.beust.kobalt.plugin.packaging.* +import com.beust.kobalt.plugin.application.* +import com.beust.kobalt.plugin.kotlin.* + +// ./kobaltw run +// ./kobaltw java:run + +val bs = buildScript { + repos(file("K:/maven/repository")) +} + +val kotlin_version = "1.1.1" +val processorJar = "net.thauvin.erik:semver:0.9.7" + +val p = project { + + name = "semver-example-kotlin" + group = "com.example" + artifactId = name + version = "0.1" + + kapt { + // needed + } + + dependencies { + apt(processorJar) + compileOnly(processorJar) + compileOnly("org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version", + "org.jetbrains.kotlin:kotlin-stdlib-js:$kotlin_version") + } + + dependenciesTest { + // compile("org.testng:testng:6.11") + } + + assemble { + jar { + } + } + + application { + mainClass = "com.example.Main" + } +} + +val java = project(p) { + name = "java" + + kapt { + // needed + } + + application { + mainClass = "com.example.Example" + } +} \ No newline at end of file diff --git a/kobalt/wrapper/kobalt-wrapper.jar b/kobalt/wrapper/kobalt-wrapper.jar new file mode 100644 index 0000000..e8143c6 Binary files /dev/null and b/kobalt/wrapper/kobalt-wrapper.jar differ diff --git a/kobalt/wrapper/kobalt-wrapper.properties b/kobalt/wrapper/kobalt-wrapper.properties new file mode 100644 index 0000000..47c86e8 --- /dev/null +++ b/kobalt/wrapper/kobalt-wrapper.properties @@ -0,0 +1 @@ +kobalt.version=1.0.74 \ No newline at end of file diff --git a/kobaltw b/kobaltw new file mode 100644 index 0000000..c5186d5 --- /dev/null +++ b/kobaltw @@ -0,0 +1,2 @@ +#!/usr/bin/env sh +java -jar "`dirname "$0"`/kobalt/wrapper/kobalt-wrapper.jar" $* diff --git a/kobaltw.bat b/kobaltw.bat new file mode 100644 index 0000000..d578071 --- /dev/null +++ b/kobaltw.bat @@ -0,0 +1,4 @@ +@echo off +set DIRNAME=%~dp0 +if "%DIRNAME%" == "" set DIRNAME=. +java -jar "%DIRNAME%/kobalt/wrapper/kobalt-wrapper.jar" %* diff --git a/src/test/kotlin/com/example/MainTest.kt b/src/test/kotlin/com/example/MainTest.kt deleted file mode 100644 index 96458e9..0000000 --- a/src/test/kotlin/com/example/MainTest.kt +++ /dev/null @@ -1,8 +0,0 @@ -package com.example - -import org.testng.annotations.Test - -class ExampleTest { - @Test - fun f() = println("Running test") -} \ No newline at end of file