added support for zstd packages

This commit is contained in:
2020-05-04 16:23:21 +01:00
parent a1ef2f6b05
commit ab082860c9
34 changed files with 786 additions and 406 deletions

View File

@@ -3,51 +3,35 @@ import org.oggio88.sbt.ConfigurationFile._
name := "jpacrepo"
organization := "com.oggio88"
organization := "net.woggioni"
version := "2.0"
resolvers += Resolver.mavenLocal
libraryDependencies += "org.tukaani" % "xz" % "1.6"
libraryDependencies += "org.slf4j" % "slf4j-api" % "1.7.25"
libraryDependencies += "org.hibernate" % "hibernate-jpamodelgen" % "5.4.2.Final" % Provided
libraryDependencies += "org.apache.commons" % "commons-compress" % "1.14"
libraryDependencies += "org.projectlombok" % "lombok" % "1.18.8" % Provided
libraryDependencies += "javax" % "javaee-api" % "7.0" % Provided
scalaVersion := "2.13.2"
libraryDependencies += "junit" % "junit" % "4.12" % Test
libraryDependencies += "com.novocode" % "junit-interface" % "0.11" % Test
libraryDependencies += "com.thoughtworks.xstream" % "xstream" % "1.4.10" % Test
libraryDependencies += "commons-io" % "commons-io" % "2.5" % Test
libraryDependencies += "org.jboss" % "jboss-ejb-client" % "4.0.18.Final" % Test
libraryDependencies += "org.apache.logging.log4j" % "log4j-slf4j-impl" % "2.11.2" % Test
libraryDependencies += "org.apache.logging.log4j" % "log4j-core" % "2.11.2" % Test
libraryDependencies += "org.apache.logging.log4j" % "log4j-api" % "2.11.2" % Test
libraryDependencies += "org.tukaani" % "xz" % Versions.xz
libraryDependencies += "org.slf4j" % "slf4j-api" % Versions.slf4j
libraryDependencies += "net.woggioni" % "jzstd" % Versions.jzstd
libraryDependencies += "net.woggioni" % "jwo" % Versions.jwo
libraryDependencies += "org.apache.commons" % "commons-compress" % Versions.`common-compress`
//libraryDependencies += "org.jboss.resteasy" % "resteasy-undertow" % "3.0.4.Final" % Test
//libraryDependencies += "io.undertow" % "undertow-core" % "2.0.20.Final" % Test
//libraryDependencies += "io.undertow" % "undertow-servlet" % "2.0.20.Final" % Test
libraryDependencies += "org.hibernate" % "hibernate-jpamodelgen" % Versions.hibernate % Provided
libraryDependencies += "org.projectlombok" % "lombok" % Versions.lombok % Provided
libraryDependencies += "javax" % "javaee-api" % Versions.javaee % Provided
//libraryDependencies += "org.jboss.weld.servlet" % "weld-servlet-core" % "3.1.1.Final" % Test
libraryDependencies += "org.jboss.weld.se" % "weld-se-core" % "3.1.1.Final" % Test
libraryDependencies += "com.h2database" % "h2" % "1.4.197" % Test
libraryDependencies += "org.hibernate" % "hibernate-core" % "5.3.6.Final" % Test
libraryDependencies += "org.jboss" % "jboss-ejb-client" % Versions.jbossEjbClient % Test
libraryDependencies += "org.apache.logging.log4j" % "log4j-slf4j-impl" % Versions.log4j % Test
libraryDependencies += "org.jboss.weld.se" % "weld-se-core" % Versions.weld % Test
libraryDependencies += "com.h2database" % "h2" % Versions.h2 % Test
libraryDependencies += "org.hibernate" % "hibernate-core" % Versions.hibernate % Test
libraryDependencies += "org.jboss.resteasy" % "resteasy-client" % Versions.restEasy % Test
libraryDependencies += "org.jboss.resteasy" % "resteasy-jackson2-provider" % Versions.restEasy % Test
libraryDependencies += "org.scalatest" %% "scalatest" % Versions.scalatest % Test
//libraryDependencies += "io.smallrye" % "smallrye-config" % "1.3.5" % Test
//libraryDependencies += "org.jboss.logging" % "jboss-logging-processor" % "2.2.0.Final" % Test
//libraryDependencies += "org.eclipse.microprofile.config" % "microprofile-config-api" % "1.3" % Test
//libraryDependencies += "org.jboss.spec.javax.ws.rs" % "jboss-jaxrs-api_2.1_spec" % "1.0.2.Final" % Test
//libraryDependencies += "org.reactivestreams" % "reactive-streams" % "1.0.2" % Test
//libraryDependencies += "org.jboss.spec.javax.xml.bind" % "jboss-jaxb-api_2.3_spec" % "1.0.1.Final" % Test
//libraryDependencies += "javax.activation" % "activation" % "1.1.1" % Test
//libraryDependencies += "javax.validation" % "validation-api" % "2.0.1.Final" % Test
//
//libraryDependencies += "org.jboss.resteasy" % "resteasy-cdi" % "4.0.0.Final" % Test
libraryDependencies += "org.jboss.resteasy" % "resteasy-jaxrs" % "3.0.11.Final" % Test
libraryDependencies += "org.jboss.resteasy" % "resteasy-client" % "3.0.11.Final" % Test
libraryDependencies += "org.jboss.resteasy" % "resteasy-jackson-provider" % "3.0.11.Final" % Test
libraryDependencies += "org.jboss.resteasy" % "resteasy-jaxb-provider" % "3.0.11.Final" % Test
enablePlugins(WarPlugin)
enablePlugins(WildflyPlugin)
@@ -56,21 +40,24 @@ enablePlugins(NimPlugin)
nimCompilerParameters in CompileNim := Seq("-d:release", "-d:serverURL=")
sources in CompileNim := Seq(baseDirectory.value / "nim" / "src" / "jpacrepo.nim")
//fork in Test := true
webappWebInfClasses := true
Test / run / javaOptions += "-Dnet.woggioni.jpacrepo.configuration.file=conf/server.properties"
Test / run / fork := true
webappPostProcess := {
val baseDir = baseDirectory.value / "nim" / "static"
val nimOutput = (compileNim in CompileNim).value
println(nimOutput)
webappDir: File =>
{
webappDir: File => {
IO.copyFile(baseDir / "index.html", webappDir / "index.html")
IO.copyFile(baseDir / "jpacrepo.css", webappDir / "jpacrepo.css")
nimOutput.foreach(file => IO.copyFile(file, webappDir / file.getName))
}
}
lazy val datasourceJNDI = SettingKey[String]("datasource-jndi", "JNDI name of the application datasource")
lazy val databaseAction = SettingKey[String]("database-action",
"value of the property \"javax.persistence.schema-generation.database.action\" in the persistence unit")