-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.sbt
45 lines (41 loc) · 1.32 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
43
44
45
import scala.sys.process._
import scala.language.postfixOps
Global / onChangedBuildSource := ReloadOnSourceChanges
val scala3Version = "3.0.0"
lazy val root = project
.in(file("."))
.enablePlugins(ScalaJSPlugin, SbtIndigo)
.settings(
name := "roguelike-lib",
version := "0.0.1",
scalaVersion := scala3Version,
organization := "io.indigoengine",
libraryDependencies ++= Seq(
"org.scalameta" %%% "munit" % "0.7.26" % Test
),
testFrameworks += new TestFramework("munit.Framework"),
Test / scalaJSLinkerConfig ~= { _.withModuleKind(ModuleKind.CommonJSModule) },
showCursor := true,
libraryDependencies ++= Seq(
"io.indigoengine" %%% "indigo-json-circe" % "0.9.0",
"io.indigoengine" %%% "indigo" % "0.9.0",
"io.indigoengine" %%% "indigo-extras" % "0.9.0"
)
)
.settings(
Compile / sourceGenerators += Def.task {
TileCharGen
.gen(
"DfTiles", // Class/module name.
"indigo.lib.roguelike", // fully qualified package name
(Compile / sourceManaged).value, // Managed sources (output) directory for the generated classes
10, // Character width
10 // Character height
)
}.taskValue
)
.settings(
code := { "code ." ! }
)
lazy val code =
taskKey[Unit]("Launch VSCode in the current directory")