sqlboiler/main.go
Patrick O'brien af1201e86e Moved config init to main func & add config_test
* Split cfg object into testCfg and cfg
* Added tests for loading toml config from file
2016-03-21 01:57:25 +10:00

25 lines
469 B
Go

/*
SQLBoiler is a tool to generate Go boilerplate code for database interactions.
So far this includes struct definitions and database statement helper functions.
*/
package main
import (
"fmt"
"os"
"github.com/pobri19/sqlboiler/cmds"
)
func main() {
// Load the config.toml file
cmds.LoadConfigFile("config.toml")
// Execute SQLBoiler
if err := cmds.SQLBoiler.Execute(); err != nil {
fmt.Printf("Failed to execute SQLBoiler: %s", err)
os.Exit(-1)
}
}