mirror of
https://github.com/ethauvin/kobalt.git
synced 2025-04-26 08:27:12 -07:00
Documentation for the properties.
This commit is contained in:
parent
bebd088195
commit
bb6f9e115f
3 changed files with 28 additions and 14 deletions
|
@ -7,7 +7,8 @@ package com.beust.kobalt.api.annotation
|
|||
annotation class Directive
|
||||
|
||||
@Retention(AnnotationRetention.RUNTIME)
|
||||
annotation class Task(val name: String,
|
||||
annotation class Task(
|
||||
val name: String,
|
||||
val description: String,
|
||||
|
||||
/** Tasks that this task depends on */
|
||||
|
@ -24,11 +25,23 @@ annotation class Task(val name: String,
|
|||
* Plugins that export properties should annotate those with this annotation so they can be documented.
|
||||
*/
|
||||
@Retention(AnnotationRetention.RUNTIME)
|
||||
annotation class ExportedPluginProperty
|
||||
annotation class ExportedPluginProperty(
|
||||
/** Documentation for this property */
|
||||
val doc: String = "",
|
||||
|
||||
/** The type of this property */
|
||||
val type: String = ""
|
||||
)
|
||||
|
||||
/**
|
||||
* Plugins that export properties on the Project instance should annotate those with this annotation so
|
||||
* they can be documented.
|
||||
*/
|
||||
@Retention(AnnotationRetention.RUNTIME)
|
||||
annotation class ExportedProjectProperty
|
||||
annotation class ExportedProjectProperty(
|
||||
/** Documentation for this property */
|
||||
val doc: String = "",
|
||||
|
||||
/** The type of this property */
|
||||
val type: String = ""
|
||||
)
|
||||
|
|
|
@ -26,7 +26,7 @@ abstract class JvmCompilerPlugin @Inject constructor(
|
|||
open val jvmCompiler: JvmCompiler) : BasePlugin() {
|
||||
|
||||
companion object {
|
||||
@ExportedProjectProperty
|
||||
@ExportedProjectProperty(doc = "The location of the build directory", type = "String")
|
||||
const val BUILD_DIR = "buildDir"
|
||||
|
||||
const val TASK_CLEAN = "clean"
|
||||
|
|
|
@ -39,13 +39,14 @@ class PackagingPlugin @Inject constructor(val dependencyManager : DependencyMana
|
|||
companion object {
|
||||
const val PLUGIN_NAME = "packaging"
|
||||
|
||||
@ExportedProjectProperty
|
||||
@ExportedProjectProperty(doc = "Where the libraries are saved", type = "String")
|
||||
const val LIBS_DIR = "libsDir"
|
||||
|
||||
@ExportedProjectProperty
|
||||
@ExportedProjectProperty(doc = "The name of the jar file", type = "String")
|
||||
const val JAR_NAME = "jarName"
|
||||
|
||||
@ExportedProjectProperty
|
||||
@ExportedProjectProperty(doc = "The list of packages produced for this project",
|
||||
type = "List<PackageConfig>")
|
||||
const val PACKAGES = "packages"
|
||||
|
||||
const val TASK_ASSEMBLE: String = "assemble"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue