Update CircleCI to support MySQL

This commit is contained in:
go-jet 2019-08-08 12:02:32 +02:00
parent f9b900b303
commit 0ab25e4464
28 changed files with 198 additions and 240 deletions

View file

@ -1,6 +1,7 @@
package utils
import (
"database/sql"
"github.com/go-jet/jet/internal/3rdparty/snaker"
"go/format"
"os"
@ -79,6 +80,14 @@ func CleanUpGeneratedFiles(dir string) error {
return nil
}
func DBClose(db *sql.DB) {
if db == nil {
return
}
db.Close()
}
// DirExists checks if folder at path exist.
func DirExists(path string) (bool, error) {
_, err := os.Stat(path)