Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

-Xsource:3 #121

Merged
merged 1 commit into from
Sep 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ name := "slick-codegen-example"
inThisBuild(
List(
scalaVersion := "2.13.15",
scalacOptions += "-Xsource:3",
githubWorkflowPublishTargetBranches := Seq(),
githubWorkflowBuild += WorkflowStep.Sbt(List("run")),
githubWorkflowJavaVersions := Seq(JavaSpec.temurin("11"))
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,19 @@
package slick.examples.codegen

import slick.jdbc.H2Profile

object Tables extends demo.Tables {
// or just use object demo.Tables, which is hard-wired to the driver stated during generation
override val profile = slick.jdbc.H2Profile
override val profile: H2Profile.type = slick.jdbc.H2Profile
}

import scala.concurrent.Await
import scala.concurrent.duration._
import scala.concurrent.ExecutionContext.Implicits.global
import scala.concurrent.duration.*
import scala.language.postfixOps

import Tables._
import Tables.profile.api._
import scala.concurrent.ExecutionContext.Implicits.global
import slick.examples.codegen.Tables.*
import slick.examples.codegen.Tables.profile.api.*

object Example extends App {
// connection info for a pre-populated throw-away, in-memory db for this demo, which is freshly initialized on every
Expand Down