mirror of
https://github.com/TheAnachronism/docspell.git
synced 2025-06-22 02:18:26 +00:00
Addon docs
This commit is contained in:
22
build.sbt
22
build.sbt
@ -966,8 +966,28 @@ val website = project
|
||||
)
|
||||
IO.append(target, IO.readBytes(changelog))
|
||||
Seq(target)
|
||||
}.taskValue
|
||||
}.taskValue,
|
||||
zolaPrepare := {
|
||||
val log = streams.value.log
|
||||
log.info("Generating examples…")
|
||||
val templateOut = baseDirectory.value / "site" / "templates" / "shortcodes"
|
||||
IO.createDirectory(templateOut)
|
||||
|
||||
// sbt crashes when interpolating values into the string in `toTask`
|
||||
// this is the reason for the followingy construct…
|
||||
(Compile / run).toTask(s" addon-output /tmp/addon-output.json").value
|
||||
(Compile / run).toTask(s" item-data /tmp/item-data.json").value
|
||||
(Compile / run).toTask(s" item-args /tmp/item-args.json").value
|
||||
(Compile / run).toTask(s" file-meta /tmp/file-meta.json").value
|
||||
|
||||
val inputs = List("addon-output", "item-data", "item-args", "file-meta")
|
||||
|
||||
inputs.foreach { name =>
|
||||
IO.move(file(s"/tmp/$name.json"), templateOut / name)
|
||||
}
|
||||
}
|
||||
)
|
||||
.dependsOn(addonlib, joex)
|
||||
|
||||
val root = project
|
||||
.in(file("."))
|
||||
|
Reference in New Issue
Block a user