1
0
mirror of https://github.com/beego/bee.git synced 2025-06-12 10:00:41 +00:00

Merge pull request #559 from s00500/develop

Adds  "-dir" option to migrate command to set migrations directory
This commit is contained in:
Faissal Elamraoui
2019-01-16 07:47:03 +01:00
committed by GitHub
3 changed files with 40 additions and 20 deletions

View File

@ -44,7 +44,7 @@ func GenerateScaffold(sname, fields, currpath, driver, conn string) {
// Run the migration
beeLogger.Log.Infof("Do you want to migrate the database? [Yes|No] ")
if utils.AskForConfirmation() {
migrate.MigrateUpdate(currpath, driver, conn)
migrate.MigrateUpdate(currpath, driver, conn, "")
}
beeLogger.Log.Successf("All done! Don't forget to add beego.Router(\"/%s\" ,&controllers.%sController{}) to routers/route.go\n", sname, strings.Title(sname))
}