aboutsummaryrefslogtreecommitdiff
path: root/src/main/scala/NamespacedCodegen.scala
diff options
context:
space:
mode:
authorStewart Stewart <stewinsalot@gmail.com>2016-11-29 11:38:49 -0800
committerStewart Stewart <stewinsalot@gmail.com>2016-11-29 11:38:49 -0800
commita27bc4756bdb0ac14abd7d6020233b87eb6048b9 (patch)
tree7f33e57afb300f52f686de8d463d2b9b52665afa /src/main/scala/NamespacedCodegen.scala
parent1dd63c4715b6ff3485325715f94827e40b782347 (diff)
downloadslick-codegen-plugin-a27bc4756bdb0ac14abd7d6020233b87eb6048b9.tar.gz
slick-codegen-plugin-a27bc4756bdb0ac14abd7d6020233b87eb6048b9.tar.bz2
slick-codegen-plugin-a27bc4756bdb0ac14abd7d6020233b87eb6048b9.zip
try early initializing jdbc driver
Diffstat (limited to 'src/main/scala/NamespacedCodegen.scala')
-rw-r--r--src/main/scala/NamespacedCodegen.scala2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/main/scala/NamespacedCodegen.scala b/src/main/scala/NamespacedCodegen.scala
index 4cc8054..ebee0c9 100644
--- a/src/main/scala/NamespacedCodegen.scala
+++ b/src/main/scala/NamespacedCodegen.scala
@@ -126,7 +126,9 @@ class Generator(uri: URI,
.map(_.code.mkString("\n"))
.mkString("\n\n")
val generatedSchema = s"""
+ |object ${schemaName} extends {
| val profile = slick.backend.DatabaseConfig.forConfig("${uri.getFragment()}").driver
+ |} with $schemaBaseClass {
| import profile.api._
| ${tableCode}
|