Skip to content

Commit

Permalink
add major
Browse files Browse the repository at this point in the history
  • Loading branch information
rez1dent3 committed Sep 6, 2022
1 parent 0ddf0b2 commit fa559ef
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,7 @@ func depthSuite(suite junit.Suite) []junit.Test {
func main() {
ticks := flag.Bool("ticks", false, "Time per ticks")
group := flag.Bool("group", false, "Groups by version")
major := flag.Bool("major", false, "Can only be used with a group")
rotate := flag.Bool("rotate", false, "Swap versions and names")
directory := flag.String("path", "./build", "Specify folder path")
flag.Parse()
Expand Down Expand Up @@ -120,6 +121,9 @@ func main() {
if *group {
re, _ := regexp.Compile(`\d+\.((\d+|x)(\.(\d+|x))?)`)
version = string(re.Find([]byte(_path)))
if *major {
version = string(version[0]) + ".x"
}
} else {
re := regexp.MustCompile(`junit-(.+).xml`)
version = re.FindStringSubmatch(_path)[1]
Expand Down

0 comments on commit fa559ef

Please sign in to comment.