Skip to content

Commit 18016d6

Browse files
committed
save test - revert me later
1 parent 4e2434b commit 18016d6

File tree

3 files changed

+9
-4
lines changed

3 files changed

+9
-4
lines changed

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -317,7 +317,7 @@ replace github.com/hashicorp/go-version => github.com/6543/go-version v1.3.1
317317

318318
replace github.com/shurcooL/vfsgen => github.com/lunny/vfsgen v0.0.0-20220105142115-2c99e1ffdfa0
319319

320-
replace github.com/nektos/act => gitea.com/gitea/act v0.261.4
320+
replace github.com/nektos/act => gitea.com/badhezi/act v0.0.1
321321

322322
// TODO: the only difference is in `PutObject`: the fork doesn't use `NewVerifyingReader(r, sha256.New(), oid, expectedSize)`, need to figure out why
323323
replace github.com/charmbracelet/git-lfs-transfer => gitea.com/gitea/git-lfs-transfer v0.2.0

go.sum

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@ dario.cat/mergo v1.0.1 h1:Ra4+bf83h2ztPIQYNP99R6m+Y7KfnARDfID+a+vLl4s=
1414
dario.cat/mergo v1.0.1/go.mod h1:uNxQE+84aUszobStD9th8a29P2fMDhsBdgRYvZOxGmk=
1515
filippo.io/edwards25519 v1.1.0 h1:FNf4tywRC1HmFuKW5xopWpigGjJKiJSV0Cqo0cJWDaA=
1616
filippo.io/edwards25519 v1.1.0/go.mod h1:BxyFTGdWcka3PhytdK4V28tE5sGfRvvvRV7EaN4VDT4=
17-
gitea.com/gitea/act v0.261.4 h1:Tf9eLlvsYFtKcpuxlMvf9yT3g4Hshb2Beqw6C1STuH8=
18-
gitea.com/gitea/act v0.261.4/go.mod h1:Pg5C9kQY1CEA3QjthjhlrqOC/QOT5NyWNjOjRHw23Ok=
17+
gitea.com/badhezi/act v0.0.1 h1:lsJL7/BHco3XJyFqI1GJKc0VTX0TPxg/tvsUwAcRiKU=
18+
gitea.com/badhezi/act v0.0.1/go.mod h1:Pg5C9kQY1CEA3QjthjhlrqOC/QOT5NyWNjOjRHw23Ok=
1919
gitea.com/gitea/git-lfs-transfer v0.2.0 h1:baHaNoBSRaeq/xKayEXwiDQtlIjps4Ac/Ll4KqLMB40=
2020
gitea.com/gitea/git-lfs-transfer v0.2.0/go.mod h1:UrXUCm3xLQkq15fu7qlXHUMlrhdlXHoi13KH2Dfiits=
2121
gitea.com/gitea/go-xsd-duration v0.0.0-20220703122237-02e73435a078 h1:BAFmdZpRW7zMQZQDClaCWobRj9uL1MR3MzpCVJvc5s4=

services/actions/notifier_helper.go

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ import (
2828
webhook_module "code.gitea.io/gitea/modules/webhook"
2929
"code.gitea.io/gitea/services/convert"
3030
notify_service "code.gitea.io/gitea/services/notify"
31+
"gopkg.in/yaml.v3"
3132

3233
"github.com/nektos/act/pkg/jobparser"
3334
"github.com/nektos/act/pkg/model"
@@ -299,8 +300,12 @@ func handleWorkflows(
299300
}
300301

301302
for _, dwf := range detectedWorkflows {
303+
var yamlData map[string]any
304+
if err := yaml.Unmarshal([]byte(dwf.Content), &yamlData); err != nil {
305+
log.Fatal(err.Error())
306+
}
302307
run := &actions_model.ActionRun{
303-
Title: strings.SplitN(commit.CommitMessage, "\n", 2)[0],
308+
Title: yamlData["run-name"].(string),
304309
RepoID: input.Repo.ID,
305310
OwnerID: input.Repo.OwnerID,
306311
WorkflowID: dwf.EntryName,

0 commit comments

Comments
 (0)