-
Notifications
You must be signed in to change notification settings - Fork 1
/
build.sbt
42 lines (33 loc) · 1.08 KB
/
build.sbt
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
import scalapb.compiler.Version.scalapbVersion
name := "protobuf-javascript-esample"
enablePlugins(PlayScala)
scalaVersion := "2.13.15"
licenses := Seq("MIT License" -> url("https://www.opensource.org/licenses/mit-license"))
scalacOptions ++= (
"-deprecation" ::
"-unchecked" ::
"-language:existentials" ::
"-language:higherKinds" ::
"-language:implicitConversions" ::
Nil
)
shellPrompt := { state =>
val branch = if(file(".git").exists){
sys.process.Process("git branch").lineStream_!.find{_.head == '*'}.map{_.drop(1)}.getOrElse("")
}else ""
Project.extract(state).currentRef.project + branch + " > "
}
PB.targets in Compile := Seq(
protocbridge.Target(
PB.gens.js,
(baseDirectory in LocalRootProject).value / "public" / "javascripts",
Seq("library=my-protobuf,binary")
)
)
PB.protoSources in Compile += PB.externalIncludePath.value
libraryDependencies ++= Seq(
guice,
"org.webjars" %% "webjars-play" % "3.0.2",
"org.webjars" % "closure-library" % "20150412-848686a",
"com.thesamet.scalapb" %% "scalapb-runtime" % scalapbVersion % "protobuf",
)