1
0
Fork 0
mirror of https://github.com/ethauvin/kobalt-line-count.git synced 2025-04-25 19:17:11 -07:00

New Kobalt.findPlugin() API

This commit is contained in:
Cedric Beust 2015-10-11 12:04:43 -07:00
parent 3989ef293d
commit 5e9b3d0000
4 changed files with 5 additions and 5 deletions

View file

@ -15,7 +15,7 @@ fun main(argv: Array<String>) {
com.beust.kobalt.main(argv)
}
public class LineCountMain : BasePlugin(), KobaltLogger {
public class LineCountPlugin : BasePlugin(), KobaltLogger {
companion object {
const val NAME : String = "kobalt-line-count"
}
@ -64,7 +64,7 @@ data class LineCountInfo(var suffix: String = "**kt")
public fun lineCount(init: LineCountInfo.() -> Unit): LineCountInfo {
with(LineCountInfo()) {
init()
(Plugins.getPlugin(LineCountMain.NAME) as LineCountMain).info = this
(Kobalt.findPlugin(LineCountPlugin.NAME) as LineCountPlugin).info = this
return this
}
}