From 34dcabbeb9d30e2009c81c76cd5c39081cd49d8c Mon Sep 17 00:00:00 2001 From: Cedric Beust Date: Sat, 3 Oct 2015 15:58:25 -0700 Subject: [PATCH] 0.138 --- .gitignore | 3 +++ .idea/kannotator.xml | 6 ++++++ Build.kt | 19 +++---------------- kobalt/wrapper/kobalt-wrapper.properties | 2 +- .../com/beust/kobalt/plugin/linecount/Main.kt | 4 ++-- 5 files changed, 15 insertions(+), 19 deletions(-) create mode 100644 .gitignore create mode 100644 .idea/kannotator.xml diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..9b0b5ad --- /dev/null +++ b/.gitignore @@ -0,0 +1,3 @@ +.idea +.kobalt + diff --git a/.idea/kannotator.xml b/.idea/kannotator.xml new file mode 100644 index 0000000..9b05217 --- /dev/null +++ b/.idea/kannotator.xml @@ -0,0 +1,6 @@ + + + + + \ No newline at end of file diff --git a/Build.kt b/Build.kt index 30ad064..962b519 100644 --- a/Build.kt +++ b/Build.kt @@ -1,5 +1,5 @@ import com.beust.kobalt.* -import com.beust.kobalt.plugin.packaging.packaging +import com.beust.kobalt.plugin.packaging.* import com.beust.kobalt.plugin.kotlin.* val repos = repos("https://dl.bintray.com/cbeust/maven/") @@ -9,26 +9,13 @@ val project = kotlinProject { group = "com.beust.kobalt" artifactId = name version = "0.2" - directory = "/Users/beust/kotlin/kobalt-line-count" - - sourceDirectories { - path("src/main/kotlin") - } - - sourceDirectoriesTest { - path() - } dependencies { - compile("com.beust:kobalt:0.71") + compile("com.beust:kobalt:0.139") } - -// dependenciesTest { -// compile("org.testng:testng:6.9.5") -// } } -val packProject = packaging(project) { +val packProject = assemble(project) { jar { manifest { attributes("Kobalt-Plugin-Class", "com.beust.kobalt.plugin.linecount.Main") diff --git a/kobalt/wrapper/kobalt-wrapper.properties b/kobalt/wrapper/kobalt-wrapper.properties index c8812a5..5334a68 100644 --- a/kobalt/wrapper/kobalt-wrapper.properties +++ b/kobalt/wrapper/kobalt-wrapper.properties @@ -1 +1 @@ -kobalt.version=0.71 \ No newline at end of file +kobalt.version=0.139 \ No newline at end of file diff --git a/src/main/kotlin/com/beust/kobalt/plugin/linecount/Main.kt b/src/main/kotlin/com/beust/kobalt/plugin/linecount/Main.kt index 7cbd367..525390f 100644 --- a/src/main/kotlin/com/beust/kobalt/plugin/linecount/Main.kt +++ b/src/main/kotlin/com/beust/kobalt/plugin/linecount/Main.kt @@ -4,7 +4,7 @@ import com.beust.kobalt.api.BasePlugin import com.beust.kobalt.internal.TaskResult import java.nio.file.attribute.BasicFileAttributes -import com.beust.kobalt.api.Project +import com.beust.kobalt.api.* import com.beust.kobalt.api.annotation.Task import com.beust.kobalt.misc.KobaltLogger import java.nio.file.* @@ -12,7 +12,7 @@ import java.nio.file.* public class Main : BasePlugin(), KobaltLogger { override val name = "kobalt-line-count" - override fun apply(project: Project) { + override fun apply(project: Project, context: KobaltContext) { println("*** Applying plugin ${name} with project ${project}") }