fix: modify logic of generating empty project

This commit is contained in:
xucong053
2022-05-26 22:06:02 +08:00
parent ef73243e04
commit 434decaa78
14 changed files with 48 additions and 57 deletions

View File

@@ -24,7 +24,9 @@ var scaffoldCmd = &cobra.Command{
}
var pluginType scaffold.PluginType
if ignorePlugin {
if empty {
pluginType = scaffold.Empty
} else if ignorePlugin {
pluginType = scaffold.Ignore
} else if genGoPlugin {
pluginType = scaffold.Go
@@ -32,7 +34,7 @@ var scaffoldCmd = &cobra.Command{
pluginType = scaffold.Py // default
}
err := scaffold.CreateScaffold(args[0], pluginType, empty, force)
err := scaffold.CreateScaffold(args[0], pluginType, force)
if err != nil {
log.Error().Err(err).Msg("create scaffold project failed")
os.Exit(1)