From d561868a7605e046adf424495383447522b1c15c Mon Sep 17 00:00:00 2001 From: Star Date: Thu, 4 Jul 2024 18:04:30 +0800 Subject: [PATCH] fix co+ bug --- main.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/main.go b/main.go index 10b1ad2..c156bdd 100644 --- a/main.go +++ b/main.go @@ -143,8 +143,8 @@ func addGitTag(args []string) bool { } } - if len(os.Args) > 2 { - newVer = os.Args[2] + if len(args) > 0 { + newVer = args[0] } else { versionParts := strings.Split(oldVer, ".") v, err := strconv.Atoi(versionParts[len(versionParts)-1])