-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.sbt
More file actions
81 lines (55 loc) · 2.88 KB
/
Copy pathbuild.sbt
File metadata and controls
81 lines (55 loc) · 2.88 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
import com.typesafe.config.ConfigFactory
import scala.util.Properties
lazy val conf = ConfigFactory.parseFile(new File("src/main/resources/application.conf"))
name := "Fuzzy"
version := "0.1"
scalaVersion := "2.12.8"
scalacOptions += "-Ypartial-unification"
libraryDependencies += "com.typesafe.akka" %% "akka-http" % "10.1.5"
libraryDependencies += "com.typesafe.akka" %% "akka-stream" % "2.5.12"
libraryDependencies += "com.typesafe.akka" %% "akka-testkit" % "2.5.22" % Test
libraryDependencies += "com.typesafe.akka" %% "akka-http-spray-json" % "10.1.5"
libraryDependencies += "org.http4s" %% "http4s-blaze-server" % "0.19.0"
libraryDependencies += "org.http4s" %% "http4s-dsl" % "0.19.0"
libraryDependencies +="co.fs2" %% "fs2-core" % "1.0.4"
libraryDependencies +="co.fs2" %% "fs2-io" % "1.0.4"
libraryDependencies += "com.typesafe.scala-logging" %% "scala-logging" % "3.9.0"
libraryDependencies += "ch.qos.logback" % "logback-classic" % "1.2.3"
libraryDependencies += "org.typelevel" %% "cats-core" % "1.5.0"
libraryDependencies += "commons-net" % "commons-net" % "3.6"
libraryDependencies += "org.scalatest" %% "scalatest" % "3.0.5" % "test"
libraryDependencies += "org.scalamock" % "scalamock_2.12" % "4.1.0"
libraryDependencies += "org.tpolecat" %% "doobie-core" % "0.6.0"
libraryDependencies += "org.tpolecat" %% "doobie-postgres" % "0.6.0"
libraryDependencies += "org.tpolecat" %% "doobie-specs2" % "0.6.0"
libraryDependencies += "org.tpolecat" %% "doobie-scalatest" % "0.6.0"
libraryDependencies += "io.circe" %% "circe-core" % "0.10.0"
libraryDependencies += "io.circe" %% "circe-generic" % "0.10.0"
libraryDependencies += "io.circe" %% "circe-parser" % "0.10.0"
libraryDependencies += "com.github.pureconfig" %% "pureconfig" % "0.10.1"
libraryDependencies += "com.chuusai" %% "shapeless" % "2.3.3"
libraryDependencies += "org.flywaydb" % "flyway-core" % "5.2.4"
resolvers += "jitpack" at "https://jitpack.io"
resolvers += "ivy2" at "file://"+Path.userHome.absolutePath+"/.ivy2/local"
libraryDependencies += "com.github.droptheplot" % "scala2html" % "1.0.0"
enablePlugins(FlywayPlugin, JavaAppPackaging)
flywayLocations += conf.getString(s"$env.jdbc.migrations")
val env: String = Properties.envOrElse("FUZZY_ENV", "development")
flywayUrl := conf.getString(s"$env.jdbc.url")
flywayUser := conf.getString(s"$env.jdbc.user")
flywayPassword := conf.getString(s"$env.jdbc.pass")
flywayUrl in Test := conf.getString("test.jdbc.url")
flywayUser in Test := conf.getString("test.jdbc.user")
flywayPassword in Test := conf.getString("test.jdbc.pass")
initialCommands in console :=
"""
|import fuzzy.Main
|import fuzzy.repositories._
|import fuzzy.entities.Config
|import pureconfig.error.ConfigReaderFailures
|import pureconfig.generic.auto._
|import doobie.implicits._
|
|var config = pureconfig.loadConfig[Config]
|var db = Main.Database(config.right.get)
|""".stripMargin