mirror of
https://github.com/go-gitea/gitea.git
synced 2026-09-22 22:15:29 +02:00
fix: Adjust the matrix functionality
Signed-off-by: Pascal Zimmermann <pascal.zimmermann@theiotstudio.com>
This commit is contained in:
@@ -121,7 +121,6 @@ require (
|
||||
google.golang.org/grpc v1.80.0
|
||||
google.golang.org/protobuf v1.36.11
|
||||
gopkg.in/ini.v1 v1.67.1
|
||||
gopkg.in/yaml.v3 v3.0.1
|
||||
mvdan.cc/xurls/v2 v2.6.0
|
||||
strk.kbt.io/projects/go/libravatar v0.0.0-20260301104140-add494e31dab
|
||||
xorm.io/builder v0.3.13
|
||||
@@ -282,6 +281,7 @@ require (
|
||||
golang.org/x/tools v0.43.0 // indirect
|
||||
google.golang.org/genproto/googleapis/rpc v0.0.0-20260401020348-3a24fdc17823 // indirect
|
||||
gopkg.in/warnings.v0 v0.1.2 // indirect
|
||||
gopkg.in/yaml.v3 v3.0.1 // indirect
|
||||
)
|
||||
|
||||
ignore (
|
||||
|
||||
@@ -53,7 +53,7 @@ func PrepareRunAndInsert(ctx context.Context, content []byte, run *actions_model
|
||||
run.Title = jobs[0].RunName
|
||||
}
|
||||
|
||||
if err = InsertRun(ctx, run, jobs, vars, inputsWithDefaults); err != nil {
|
||||
if err = InsertRun(ctx, run, content, jobs, vars, inputsWithDefaults); err != nil {
|
||||
return fmt.Errorf("InsertRun: %w", err)
|
||||
}
|
||||
|
||||
@@ -75,7 +75,7 @@ func PrepareRunAndInsert(ctx context.Context, content []byte, run *actions_model
|
||||
|
||||
// InsertRun inserts a run
|
||||
// The title will be cut off at 255 characters if it's longer than 255 characters.
|
||||
func InsertRun(ctx context.Context, run *actions_model.ActionRun, jobs []*jobparser.SingleWorkflow, vars map[string]string, inputs map[string]any) error {
|
||||
func InsertRun(ctx context.Context, run *actions_model.ActionRun, content []byte, jobs []*jobparser.SingleWorkflow, vars map[string]string, inputs map[string]any) error {
|
||||
return db.WithTx(ctx, func(ctx context.Context) error {
|
||||
index, err := db.GetNextResourceIndex(ctx, "action_run_index", run.RepoID)
|
||||
if err != nil {
|
||||
@@ -103,7 +103,7 @@ func InsertRun(ctx context.Context, run *actions_model.ActionRun, jobs []*jobpar
|
||||
}
|
||||
|
||||
// Extract raw strategies from the original workflow before parsing
|
||||
rawStrategies, err := ExtractRawStrategies(workflowContent)
|
||||
rawStrategies, err := ExtractRawStrategies(content)
|
||||
if err != nil {
|
||||
log.Warn("Failed to extract raw strategies from workflow: %v", err)
|
||||
// Continue without raw strategies - jobs will work but dynamic matrix won't be supported
|
||||
|
||||
Reference in New Issue
Block a user