This commit is contained in:
anqiansong
2022-03-05 22:52:32 +08:00
committed by GitHub
parent 08a8bd7ef7
commit 68a81fea8a
11 changed files with 95 additions and 20 deletions

View File

@@ -55,8 +55,9 @@ func ApiCommand(c *cli.Context) error {
home := c.String("home")
remote := c.String("remote")
branch := c.String("branch")
if len(remote) > 0 {
repo, _ := util.CloneIntoGitHome(remote)
repo, _ := util.CloneIntoGitHome(remote, branch)
if len(repo) > 0 {
home = repo
}

View File

@@ -33,8 +33,9 @@ func GoCommand(c *cli.Context) error {
namingStyle := c.String("style")
home := c.String("home")
remote := c.String("remote")
branch := c.String("branch")
if len(remote) > 0 {
repo, _ := util.CloneIntoGitHome(remote)
repo, _ := util.CloneIntoGitHome(remote, branch)
if len(repo) > 0 {
home = repo
}

View File

@@ -67,8 +67,9 @@ func CreateServiceCommand(c *cli.Context) error {
home := c.String("home")
remote := c.String("remote")
branch := c.String("branch")
if len(remote) > 0 {
repo, _ := util.CloneIntoGitHome(remote)
repo, _ := util.CloneIntoGitHome(remote, branch)
if len(repo) > 0 {
home = repo
}