mirror of
https://github.com/JetBrains/intellij-platform-plugin-template.git
synced 2024-10-27 20:44:05 +00:00
Better handling of the Gradle plugin description extraction from the README file
This commit is contained in:
parent
79f2db0e2b
commit
df44c045e3
@ -3,6 +3,9 @@
|
|||||||
# IntelliJ Platform Plugin Template Changelog
|
# IntelliJ Platform Plugin Template Changelog
|
||||||
|
|
||||||
## [Unreleased]
|
## [Unreleased]
|
||||||
|
### Added
|
||||||
|
- Better handling of the Gradle plugin description extraction from the README file
|
||||||
|
|
||||||
### Changed
|
### Changed
|
||||||
- Gradle - remove kotlin("stdlib-jdk8") dependency to decrease the plugin artifact size
|
- Gradle - remove kotlin("stdlib-jdk8") dependency to decrease the plugin artifact size
|
||||||
|
|
||||||
|
@ -93,7 +93,13 @@ tasks {
|
|||||||
// Extract the <!-- Plugin description --> section from README.md and provide for the plugin's manifest
|
// Extract the <!-- Plugin description --> section from README.md and provide for the plugin's manifest
|
||||||
pluginDescription(closure {
|
pluginDescription(closure {
|
||||||
File("./README.md").readText().lines().run {
|
File("./README.md").readText().lines().run {
|
||||||
subList(indexOf("<!-- Plugin description -->") + 1, indexOf("<!-- Plugin description end -->"))
|
val start = "<!-- Plugin description -->"
|
||||||
|
val end = "<!-- Plugin description end -->"
|
||||||
|
|
||||||
|
if (!containsAll(listOf(start, end))) {
|
||||||
|
throw GradleException("Plugin description section not found in README.md file:\n$start ... $end")
|
||||||
|
}
|
||||||
|
subList(indexOf(start) + 1, indexOf(end))
|
||||||
}.joinToString("\n").run { markdownToHTML(this) }
|
}.joinToString("\n").run { markdownToHTML(this) }
|
||||||
})
|
})
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user