1.9.0
This commit is contained in:
parent
8a864f97a3
commit
c249dc5ae4
@ -1,25 +1,25 @@
|
|||||||
[versions]
|
[versions]
|
||||||
tools = "0.14.9-kotlin-1.9.0"
|
tools = "0.14.10-kotlin-1.9.0"
|
||||||
kotlin = "1.9.0"
|
kotlin = "1.9.0"
|
||||||
atomicfu = "0.20.2"
|
atomicfu = "0.22.0"
|
||||||
binary-compatibility-validator = "0.13.1"
|
binary-compatibility-validator = "0.13.2"
|
||||||
changelog = "2.0.0"
|
changelog = "2.1.2"
|
||||||
dokka = "1.8.10"
|
dokka = "1.8.20"
|
||||||
kotlin-jupyter = "0.11.0-360"
|
kotlin-jupyter = "0.12.0-43"
|
||||||
kotlinx-benchmark = "0.4.7"
|
kotlinx-benchmark = "0.4.9"
|
||||||
kotlinx-cli = "0.3.5"
|
kotlinx-cli = "0.3.5"
|
||||||
kotlinx-coroutines = "1.7.2"
|
kotlinx-coroutines = "1.7.3"
|
||||||
kotlinx-datetime = "0.4.0"
|
kotlinx-datetime = "0.4.0"
|
||||||
kotlinx-html = "0.8.0"
|
kotlinx-html = "0.9.1"
|
||||||
kotlinx-knit = "0.4.0"
|
kotlinx-knit = "0.4.0"
|
||||||
kotlinx-nodejs = "0.0.7"
|
kotlinx-nodejs = "0.0.7"
|
||||||
kotlinx-serialization = "1.5.1"
|
kotlinx-serialization = "1.5.1"
|
||||||
ktor = "2.3.0"
|
ktor = "2.3.3"
|
||||||
xmlutil = "0.86.0"
|
xmlutil = "0.86.1"
|
||||||
yamlkt = "0.13.0"
|
yamlkt = "0.13.0"
|
||||||
jsBom = "1.0.0-pre.546"
|
jsBom = "1.0.0-pre.618"
|
||||||
junit = "5.9.3"
|
junit = "5.9.3"
|
||||||
compose = "1.4.0"
|
compose = "1.5.0-rc01"
|
||||||
logback = "1.4.7"
|
logback = "1.4.7"
|
||||||
|
|
||||||
[libraries]
|
[libraries]
|
||||||
|
@ -205,10 +205,11 @@ public open class KScienceProjectPlugin : Plugin<Project> {
|
|||||||
val modulesString = buildString {
|
val modulesString = buildString {
|
||||||
subprojects.forEach { subproject ->
|
subprojects.forEach { subproject ->
|
||||||
// val name = subproject.name
|
// val name = subproject.name
|
||||||
subproject.extensions.findByType<KScienceReadmeExtension>()?.let { ext ->
|
subproject.extensions.findByType<KScienceReadmeExtension>()
|
||||||
|
?.let { ext: KScienceReadmeExtension ->
|
||||||
val path = subproject.path.replaceFirst(":", "").replace(":", "/")
|
val path = subproject.path.replaceFirst(":", "").replace(":", "/")
|
||||||
appendLine("\n### [$path]($path)")
|
appendLine("\n### [$path]($path)")
|
||||||
appendLine("> ${ext.description}")
|
ext.description?.let { appendLine("> ${ext.description}") }
|
||||||
appendLine(">\n> **Maturity**: ${ext.maturity}")
|
appendLine(">\n> **Maturity**: ${ext.maturity}")
|
||||||
val featureString = ext.featuresString(itemPrefix = "> - ", pathPrefix = "$path/")
|
val featureString = ext.featuresString(itemPrefix = "> - ", pathPrefix = "$path/")
|
||||||
if (featureString.isNotBlank()) {
|
if (featureString.isNotBlank()) {
|
||||||
|
@ -10,6 +10,7 @@ import kotlinx.html.stream.createHTML
|
|||||||
import kotlinx.validation.ApiValidationExtension
|
import kotlinx.validation.ApiValidationExtension
|
||||||
import org.gradle.api.Project
|
import org.gradle.api.Project
|
||||||
import org.gradle.kotlin.dsl.findByType
|
import org.gradle.kotlin.dsl.findByType
|
||||||
|
import org.intellij.lang.annotations.Language
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import java.io.StringWriter
|
import java.io.StringWriter
|
||||||
import kotlin.collections.component1
|
import kotlin.collections.component1
|
||||||
@ -32,7 +33,8 @@ private fun Template.processToString(args: Map<String, Any?>): String {
|
|||||||
|
|
||||||
|
|
||||||
public class KScienceReadmeExtension(public val project: Project) {
|
public class KScienceReadmeExtension(public val project: Project) {
|
||||||
public var description: String = project.description ?: ""
|
public var description: String? = null
|
||||||
|
get() = field ?: project.description
|
||||||
|
|
||||||
public var maturity: Maturity = Maturity.EXPERIMENTAL
|
public var maturity: Maturity = Maturity.EXPERIMENTAL
|
||||||
set(value) {
|
set(value) {
|
||||||
@ -93,7 +95,12 @@ public class KScienceReadmeExtension(public val project: Project) {
|
|||||||
/**
|
/**
|
||||||
* A plain readme feature with description
|
* A plain readme feature with description
|
||||||
*/
|
*/
|
||||||
public fun feature(id: String, ref: String? = null, name: String = id, description: () -> String) {
|
public fun feature(
|
||||||
|
id: String,
|
||||||
|
@Language("File") ref: String? = null,
|
||||||
|
name: String = id,
|
||||||
|
description: () -> String,
|
||||||
|
) {
|
||||||
features += Feature(id, description(), ref, name)
|
features += Feature(id, description(), ref, name)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user