feat(cmd/joj3): pass groups in teapot [force build]
This commit is contained in:
parent
23d586634a
commit
e7c25ca80c
|
@ -340,5 +340,6 @@ func MatchGroups(conf *Conf, conventionalCommit *ConventionalCommit) []string {
|
||||||
groups = append(groups, keyword)
|
groups = append(groups, keyword)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
slog.Info("matched groups", "groups", groups)
|
||||||
return groups
|
return groups
|
||||||
}
|
}
|
||||||
|
|
|
@ -114,7 +114,7 @@ func mainImpl() (err error) {
|
||||||
slog.Error("stage write", "error", err)
|
slog.Error("stage write", "error", err)
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
teapotResult, err = teapot.Run(confObj)
|
teapotResult, err = teapot.Run(confObj, groups)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
slog.Error("teapot run", "error", err)
|
slog.Error("teapot run", "error", err)
|
||||||
return err
|
return err
|
||||||
|
|
|
@ -23,7 +23,9 @@ type TeapotResult struct {
|
||||||
Sha string `json:"sha"`
|
Sha string `json:"sha"`
|
||||||
}
|
}
|
||||||
|
|
||||||
func Run(conf *conf.Conf) (teapotResult TeapotResult, err error) {
|
func Run(conf *conf.Conf, groups []string) (
|
||||||
|
teapotResult TeapotResult, err error,
|
||||||
|
) {
|
||||||
os.Setenv("LOG_FILE_PATH", conf.Teapot.LogPath)
|
os.Setenv("LOG_FILE_PATH", conf.Teapot.LogPath)
|
||||||
os.Setenv("_TYPER_STANDARD_TRACEBACK", "1")
|
os.Setenv("_TYPER_STANDARD_TRACEBACK", "1")
|
||||||
if env.Attr.Actor == "" ||
|
if env.Attr.Actor == "" ||
|
||||||
|
@ -59,6 +61,7 @@ func Run(conf *conf.Conf) (teapotResult TeapotResult, err error) {
|
||||||
env.Attr.RunNumber, conf.Teapot.ScoreboardPath,
|
env.Attr.RunNumber, conf.Teapot.ScoreboardPath,
|
||||||
conf.Teapot.FailedTablePath,
|
conf.Teapot.FailedTablePath,
|
||||||
conf.Name, env.Attr.Sha, env.Attr.RunID,
|
conf.Name, env.Attr.Sha, env.Attr.RunID,
|
||||||
|
strings.Join(groups, ","),
|
||||||
"--max-total-score", strconv.Itoa(conf.MaxTotalScore),
|
"--max-total-score", strconv.Itoa(conf.MaxTotalScore),
|
||||||
skipIssueArg, skipScoreboardArg,
|
skipIssueArg, skipScoreboardArg,
|
||||||
skipFailedTableArg, submitterInIssueTitleArg,
|
skipFailedTableArg, submitterInIssueTitleArg,
|
||||||
|
|
Loading…
Reference in New Issue
Block a user