Plug-in development

How to set up your environment to write a Kobalt plug-in.

Reference project

As a start up point, you can clone the kobalt-line-count project and use it as a guide line to write your own plug-in.

Build file

You can start with a simple build file:

import com.beust.kobalt.*
import com.beust.kobalt.plugin.packaging.*
import com.beust.kobalt.plugin.kotlin.*
import com.beust.kobalt.plugin.publish.*


val project = kotlinProject {
    name = "kobalt-line-count"
    group = "com.beust.kobalt"
    artifactId = name
    version = "0.1"

    dependencies {
        compile("com.beust:kobalt:0.154")
    }
}

val packProject = assemble(project) {
    mavenJars {
        manifest {
            attributes("Kobalt-Plugin-Class", "com.beust.kobalt.plugin.linecount.Main")
        }
    }
}

val jc = jcenter(project) {
    publish = true
}