Skip to content

Commit

Permalink
try out play-lila
Browse files Browse the repository at this point in the history
  • Loading branch information
Thibault Duplessis committed Aug 6, 2020
1 parent 161cb77 commit d8f5cb1
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 11 deletions.
10 changes: 4 additions & 6 deletions build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,6 @@ PlayKeys.externalizeResources := false
scriptClasspath := Seq("*")
// give a fake assets dir to make sure they're not packaged
resourceDirectory in Assets := baseDirectory.value / "public-nothanks"
// don't make an assets jar
PlayKeys.generateAssetsJar := false
// who needs JS routes right?
routesGenerator := LilaRoutesGenerator
maintainer := "[email protected]"
Expand Down Expand Up @@ -70,7 +68,7 @@ lazy val api = module("api",

lazy val i18n = module("i18n",
Seq(common, db, hub),
Seq(scalatags)
Seq(scalatags, specs2)
).settings(
sourceGenerators in Compile += Def.task {
MessageCompiler(
Expand All @@ -87,9 +85,9 @@ lazy val puzzle = module("puzzle",
reactivemongo.bundle
)

lazy val quote = module("quote",
lazy val quote = smallModule("quote",
Seq(),
Seq()
Seq(play.json)
)

lazy val video = module("video",
Expand Down Expand Up @@ -124,7 +122,7 @@ lazy val evaluation = module("evaluation",

lazy val common = module("common",
Seq(),
Seq(kamon.core, scalatags, jodaForms, scaffeine, specs2) ++ reactivemongo.bundle
Seq(kamon.core, scalatags, jodaForms, scaffeine, specs2, apacheText) ++ reactivemongo.bundle
)

lazy val rating = module("rating",
Expand Down
15 changes: 15 additions & 0 deletions project/BuildSettings.scala
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,21 @@ object BuildSettings {
srcMain
)

def smallModule(
name: String,
deps: Seq[sbt.ClasspathDep[sbt.ProjectReference]],
libs: Seq[ModuleID]
) =
Project(
name,
file("modules/" + name)
).dependsOn(deps: _*)
.settings(
libraryDependencies ++= libs,
buildSettings,
srcMain
)

val compilerOptions = Seq(
"-explaintypes",
"-feature",
Expand Down
10 changes: 6 additions & 4 deletions project/Dependencies.scala
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,17 @@ object Dependencies {
val maxmind = "com.sanoma.cda" %% "maxmind-geoip2-scala" % "1.3.1-THIB"
val prismic = "io.prismic" %% "scala-kit" % "1.2.18-THIB213"
val scrimage = "com.sksamuel.scrimage" % "scrimage-core" % "4.0.5"
val scaffeine = "com.github.blemale" %% "scaffeine" % "4.0.1" % "compile"
val scaffeine = "com.github.blemale" %% "scaffeine" % "4.0.1" % "compile"
val googleOAuth = "com.google.auth" % "google-auth-library-oauth2-http" % "0.21.1"
val scalaUri = "io.lemonlabs" %% "scala-uri" % "2.2.4"
val scalatags = "com.lihaoyi" %% "scalatags" % "0.8.5"
val lettuce = "io.lettuce" % "lettuce-core" % "5.3.2.RELEASE"
val epoll = "io.netty" % "netty-transport-native-epoll" % "4.1.51.Final" classifier "linux-x86_64"
val autoconfig = "io.methvin.play" %% "autoconfig-macros" % "0.3.2" % "provided"
val scalatest = "org.scalatest" %% "scalatest" % "3.1.0" % Test
val autoconfig = "io.methvin.play" %% "autoconfig-macros" % "0.3.2" % "provided"
val scalatest = "org.scalatest" %% "scalatest" % "3.1.0" % Test
val uaparser = "org.uaparser" %% "uap-scala" % "0.11.0"
val specs2 = "org.specs2" %% "specs2-core" % "4.10.0" % Test
val apacheText = "org.apache.commons" % "commons-text" % "1.9"

object flexmark {
val version = "0.50.50"
Expand All @@ -55,7 +57,7 @@ object Dependencies {
}

object play {
val version = "2.8.2"
val version = "2.8.2-lila_0.1"
val api = "com.typesafe.play" %% "play" % version
val json = "com.typesafe.play" %% "play-json" % "2.9.0"
}
Expand Down
2 changes: 1 addition & 1 deletion project/plugins.sbt
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
addSbtPlugin("com.typesafe.play" % "sbt-plugin" % "2.8.2")
addSbtPlugin("com.typesafe.play" % "sbt-plugin" % "2.8.2-lila_0.1")
addSbtPlugin("org.scalameta" % "sbt-scalafmt" % "2.4.2")
addSbtPlugin("ch.epfl.scala" % "sbt-bloop" % "1.4.3")

0 comments on commit d8f5cb1

Please sign in to comment.