Skip to content

Releases: typr-dev/typr

0.31.0

04 Aug 11:00

Choose a tag to compare

What's Changed

  • Fixed naming of TestInsert.scala by @develeon in #158
  • Introduce Dialect to generate code tailored to your scala version by @lervag in #156

New Contributors

Full Changelog: v0.30.0...v0.31.0

0.30.0

28 Jul 01:34
5c9e8d5

Choose a tag to compare

What's Changed

  • Make update method return Option[Row] instead of Boolean for all database libraries by @oyvindberg in #139

Full Changelog: v0.29.0...v0.30.0

0.29.0

27 Jul 23:57
69b6e50

Choose a tag to compare

What's Changed

New Contributors

Full Changelog: v0.28.0...v0.29.0

0.28.0

31 Oct 13:20
4f36771

Choose a tag to compare

What's Changed

New Contributors

Full Changelog: v0.27.0...v0.28.0

0.27.0

21 Oct 09:53
2f44343

Choose a tag to compare

What's Changed

Full Changelog: v0.26.0...v0.27.0

0.26.0

17 Aug 11:25

Choose a tag to compare

What's Changed

Full Changelog: v0.25.0...v0.26.0

0.25.0

09 Aug 11:53
346eda2

Choose a tag to compare

What's Changed

Full Changelog: v0.24.0...v0.25.0

0.24.0

26 Jul 00:01
859b8b4

Choose a tag to compare

What's Changed

Full Changelog: v0.23.0...v0.24.0

0.23.0

16 Jul 09:01
098a1bc

Choose a tag to compare

What's Changed

Full Changelog: v0.22.2...v0.23.0

Breaking changes

Need to overwriteFolder multiple source directories

generateFromDb(
  ds,
  options, 
  targetFolder = targetDir,
  testTargetFolder = Some(testTargetDir),
   selector = selector, 
   scriptsPaths = List(scriptsFolder)
-).overwriteFolder()
+).foreach(_.overwriteFolder())
 
 // add changed files to git, so you can keep them under control
 //scala.sys.process.Process(List("git", "add", targetDir.toString)).!!

need to provide a TypoDataSource instead of a java.sql.Connection

 // adapt to your instance and credentials
-implicit val c: java.sql.Connection =
-  java.sql.DriverManager.getConnection("jdbc:postgresql://localhost:6432/postgres?user=postgres&password=password")
+val ds = TypoDataSource.hikari(
+  server = "localhost", 
+  port = 6432, 
+  databaseName = "Adventureworks", 
+  username = "postgres", 
+  password = "password"
+)
 
 val options = Options(
   // customize package name for generated code
@@ -67,6 +72,7 @@
 val selector = Selector.ExcludePostgresInternal
 
 generateFromDb(
+  ds,
   options, 
   targetFolder = targetDir,
   testTargetFolder = Some(testTargetDir),

customization of Id type names

Signature of typo.Naming#idName changed so you also get a representation of all columns in the ID type, which can help you name it.

0.22.2

08 Jul 11:36

Choose a tag to compare

Full Changelog: v0.22.1...v0.22.2