feat: Add migrate (#1419)
* Add migrate * Remove unused module * refactor filename * rename refactor to migrate Co-authored-by: anqiansong <anqiansong@bytedance.com>
This commit is contained in:
@@ -23,6 +23,7 @@ import (
|
||||
"github.com/tal-tech/go-zero/tools/goctl/internal/errorx"
|
||||
"github.com/tal-tech/go-zero/tools/goctl/internal/version"
|
||||
"github.com/tal-tech/go-zero/tools/goctl/kube"
|
||||
"github.com/tal-tech/go-zero/tools/goctl/migrate"
|
||||
"github.com/tal-tech/go-zero/tools/goctl/model/mongo"
|
||||
model "github.com/tal-tech/go-zero/tools/goctl/model/sql/command"
|
||||
"github.com/tal-tech/go-zero/tools/goctl/plugin"
|
||||
@@ -45,6 +46,22 @@ var commands = []cli.Command{
|
||||
Usage: "upgrade goctl to latest version",
|
||||
Action: upgrade.Upgrade,
|
||||
},
|
||||
{
|
||||
Name: "migrate",
|
||||
Usage: "migrate from tal-tech to zeromicro",
|
||||
Description: "migrate is a transition command to help users migrate their projects from tal-tech to zeromicro version",
|
||||
Action: migrate.Migrate,
|
||||
Flags: []cli.Flag{
|
||||
cli.BoolFlag{
|
||||
Name: "verbose, v",
|
||||
Usage: "verbose enables extra logging",
|
||||
},
|
||||
cli.StringFlag{
|
||||
Name: "version",
|
||||
Usage: "the target release version of github.com/zeromicro/go-zero to refactor",
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
Name: "api",
|
||||
Usage: "generate api related files",
|
||||
|
||||
Reference in New Issue
Block a user