Add flag for controlling out path for model gen
Some checks are pending
/ test (push) Waiting to run
Some checks are pending
/ test (push) Waiting to run
This commit is contained in:
parent
349e78e433
commit
befbc07946
1 changed files with 2 additions and 1 deletions
|
@ -19,6 +19,7 @@ import (
|
|||
)
|
||||
|
||||
func main() {
|
||||
flagOutPath := flag.String("outpath", "./dbgen", "Set the path to generate to")
|
||||
other.SetupFlags()
|
||||
flag.Parse()
|
||||
other.ConfigureLogging(nil)
|
||||
|
@ -36,7 +37,7 @@ func main() {
|
|||
}
|
||||
log.Info().Msg("Connected to db")
|
||||
g := gen.NewGenerator(gen.Config{
|
||||
OutPath: "./dbgen",
|
||||
OutPath: *flagOutPath,
|
||||
Mode: gen.WithoutContext | gen.WithDefaultQuery | gen.WithQueryInterface, // generate mode
|
||||
})
|
||||
g.UseDB(db)
|
||||
|
|
Loading…
Reference in a new issue