mirror of
https://github.com/TheAnachronism/docspell.git
synced 2025-08-05 02:24:52 +00:00
@ -272,7 +272,7 @@ object Dependencies {
|
||||
).map(_ % Test)
|
||||
|
||||
val munit = Seq(
|
||||
"org.scalameta" %% "munit" % MUnitVersion,
|
||||
"org.scalameta" %% "munit" % MUnitVersion,
|
||||
"org.scalameta" %% "munit-scalacheck" % MUnitVersion
|
||||
)
|
||||
|
||||
@ -280,9 +280,9 @@ object Dependencies {
|
||||
val betterMonadicFor = "com.olegpy" %% "better-monadic-for" % BetterMonadicForVersion
|
||||
|
||||
val webjars = Seq(
|
||||
"org.webjars" % "swagger-ui" % SwaggerUIVersion,
|
||||
"org.webjars" % "viewerjs" % ViewerJSVersion,
|
||||
"org.webjars" % "clipboard.js" % ClipboardJsVersion
|
||||
"org.webjars" % "swagger-ui" % SwaggerUIVersion,
|
||||
"org.webjars" % "viewerjs" % ViewerJSVersion,
|
||||
"org.webjars" % "clipboard.js" % ClipboardJsVersion
|
||||
)
|
||||
|
||||
val icu4j = Seq(
|
||||
|
@ -54,7 +54,8 @@ object StylesPlugin extends AutoPlugin {
|
||||
val mode = stylesMode.value
|
||||
npmInstall(npm, wd, logger)
|
||||
val files = postCss(npx, inDir, outDir, wd, mode, logger) ++
|
||||
copyWebfonts(wd, outDir, logger)
|
||||
copyWebfonts(wd, outDir, logger) ++
|
||||
copyFlags(wd, outDir, logger)
|
||||
logger.info("Styles built")
|
||||
files
|
||||
},
|
||||
@ -63,6 +64,7 @@ object StylesPlugin extends AutoPlugin {
|
||||
val npm = stylesNpmCommand.value
|
||||
val wd = (LocalRootProject / baseDirectory).value
|
||||
npmInstall(npm, wd, logger)
|
||||
|
||||
}
|
||||
)
|
||||
|
||||
@ -118,4 +120,20 @@ object StylesPlugin extends AutoPlugin {
|
||||
IO.copy(fontDir.listFiles().map(f => f -> targetDir / f.name).toSeq)
|
||||
IO.listFiles(targetDir).toSeq
|
||||
}
|
||||
|
||||
def copyFlags(baseDir: File, outDir: File, logger: Logger): Seq[File] = {
|
||||
val flagDir =
|
||||
baseDir / "node_modules" / "flag-icon-css" / "flags"
|
||||
val targetDir = outDir / "flags"
|
||||
IO.createDirectory(targetDir)
|
||||
|
||||
val files = (flagDir ** "*")
|
||||
.filter(_.isFile)
|
||||
.get
|
||||
.pair(Path.relativeTo(flagDir))
|
||||
.map(t => (t._1, targetDir / t._2))
|
||||
|
||||
IO.copy(files)
|
||||
(targetDir ** "*.svg").get()
|
||||
}
|
||||
}
|
||||
|
@ -35,7 +35,7 @@ object ZolaPlugin extends AutoPlugin {
|
||||
zolaBuild := {
|
||||
val logger = streams.value.log
|
||||
logger.info("Building web site using zola ...")
|
||||
(Compile/resources).value
|
||||
(Compile / resources).value
|
||||
buildSite(zolaCommand.value, zolaRootDir.value, zolaOutputDir.value, None, logger)
|
||||
logger.info("Website built")
|
||||
},
|
||||
@ -43,7 +43,7 @@ object ZolaPlugin extends AutoPlugin {
|
||||
val logger = streams.value.log
|
||||
val baseurl = zolaTestBaseUrl.value
|
||||
logger.info("Building web site (test) using zola ...")
|
||||
(Compile/resources).value
|
||||
(Compile / resources).value
|
||||
buildSite(
|
||||
zolaCommand.value,
|
||||
zolaRootDir.value,
|
||||
|
@ -1,13 +1,13 @@
|
||||
addSbtPlugin("ch.epfl.scala" % "sbt-scalafix" % "0.9.27")
|
||||
addSbtPlugin("com.eed3si9n" % "sbt-buildinfo" % "0.10.0")
|
||||
addSbtPlugin("com.github.eikek" % "sbt-openapi-schema" % "0.7.1")
|
||||
addSbtPlugin("com.github.sbt" % "sbt-release" % "1.0.15")
|
||||
addSbtPlugin("com.github.sbt" % "sbt-pgp" % "2.1.2")
|
||||
addSbtPlugin("com.typesafe.sbt" % "sbt-ghpages" % "0.6.3")
|
||||
addSbtPlugin("com.typesafe.sbt" % "sbt-git" % "1.0.0")
|
||||
addSbtPlugin("com.typesafe.sbt" % "sbt-native-packager" % "1.8.1")
|
||||
addSbtPlugin("io.spray" % "sbt-revolver" % "0.9.1")
|
||||
addSbtPlugin("ch.epfl.scala" % "sbt-scalafix" % "0.9.27")
|
||||
addSbtPlugin("com.eed3si9n" % "sbt-buildinfo" % "0.10.0")
|
||||
addSbtPlugin("com.github.eikek" % "sbt-openapi-schema" % "0.7.1")
|
||||
addSbtPlugin("com.github.sbt" % "sbt-release" % "1.0.15")
|
||||
addSbtPlugin("com.github.sbt" % "sbt-pgp" % "2.1.2")
|
||||
addSbtPlugin("com.typesafe.sbt" % "sbt-ghpages" % "0.6.3")
|
||||
addSbtPlugin("com.typesafe.sbt" % "sbt-git" % "1.0.0")
|
||||
addSbtPlugin("com.typesafe.sbt" % "sbt-native-packager" % "1.8.1")
|
||||
addSbtPlugin("io.spray" % "sbt-revolver" % "0.9.1")
|
||||
addSbtPlugin("org.portable-scala" % "sbt-scalajs-crossproject" % "1.0.0")
|
||||
addSbtPlugin("org.scala-js" % "sbt-scalajs" % "1.5.1")
|
||||
addSbtPlugin("org.scalameta" % "sbt-scalafmt" % "2.4.2")
|
||||
addSbtPlugin("org.xerial.sbt" % "sbt-sonatype" % "3.9.7")
|
||||
addSbtPlugin("org.scala-js" % "sbt-scalajs" % "1.5.1")
|
||||
addSbtPlugin("org.scalameta" % "sbt-scalafmt" % "2.4.2")
|
||||
addSbtPlugin("org.xerial.sbt" % "sbt-sonatype" % "3.9.7")
|
||||
|
Reference in New Issue
Block a user