feat: use -version for version
All checks were successful
build / build (push) Successful in 1m16s
build / trigger-build-image (push) Successful in 6s

This commit is contained in:
张泊明518370910136 2024-10-01 01:15:31 -04:00
parent ff8f700506
commit 0826a3d14a
GPG Key ID: D47306D7062CDA9D
4 changed files with 4 additions and 4 deletions

View File

@ -39,7 +39,7 @@ jobs:
- name: Build
run: make build
- name: Version
run: ./build/joj3 -v
run: ./build/joj3 -version
- name: Test
run: |
make prepare-test

View File

@ -40,7 +40,7 @@ var Version string
// Generally, err is used for runtime errors, and checkRes is used for the result of the checks.
func main() {
var gitWhitelist, metaFile, releaseTags []string
showVersion := flag.Bool("v", false, "print current version")
showVersion := flag.Bool("version", false, "print current version")
rootDir := flag.String("root", "", "")
repo := flag.String("repo", "", "")
localList := flag.String("localList", "", "")

View File

@ -100,7 +100,7 @@ var (
func init() {
flag.StringVar(&metaConfPath, "meta-conf", "meta-conf.toml", "meta config file path")
flag.StringVar(&msg, "msg", "", "message to trigger the running, leave empty to use git commit message on HEAD")
showVersion = flag.Bool("v", false, "print current version")
showVersion = flag.Bool("version", false, "print current version")
}
func mainImpl() error {

View File

@ -12,7 +12,7 @@ import (
var Version string
func main() {
showVersion := flag.Bool("v", false, "print current version")
showVersion := flag.Bool("version", false, "print current version")
score := flag.Int("score", 0, "score")
flag.Parse()
if *showVersion {