mirror of
https://code.forgejo.org/forgejo/runner.git
synced 2025-10-10 19:32:04 +00:00
pin to v1.0.0 of github action parser
This commit is contained in:
parent
9c3a288946
commit
eb25b2a615
116 changed files with 9431 additions and 3576 deletions
42
vendor/github.com/actions/workflow-parser/parser/events.go
generated
vendored
Normal file
42
vendor/github.com/actions/workflow-parser/parser/events.go
generated
vendored
Normal file
|
@ -0,0 +1,42 @@
|
|||
package parser
|
||||
|
||||
import (
|
||||
"strings"
|
||||
)
|
||||
|
||||
// isAllowedEventType returns true if the event type is supported.
|
||||
func isAllowedEventType(eventType string) bool {
|
||||
_, ok := eventTypeWhitelist[strings.ToLower(eventType)]
|
||||
return ok
|
||||
}
|
||||
|
||||
// https://developer.github.com/actions/creating-workflows/workflow-configuration-options/#events-supported-in-workflow-files
|
||||
var eventTypeWhitelist = map[string]struct{}{
|
||||
"check_run": {},
|
||||
"check_suite": {},
|
||||
"commit_comment": {},
|
||||
"create": {},
|
||||
"delete": {},
|
||||
"deployment": {},
|
||||
"deployment_status": {},
|
||||
"fork": {},
|
||||
"gollum": {},
|
||||
"issue_comment": {},
|
||||
"issues": {},
|
||||
"label": {},
|
||||
"member": {},
|
||||
"milestone": {},
|
||||
"page_build": {},
|
||||
"project_card": {},
|
||||
"project_column": {},
|
||||
"project": {},
|
||||
"public": {},
|
||||
"pull_request_review_comment": {},
|
||||
"pull_request_review": {},
|
||||
"pull_request": {},
|
||||
"push": {},
|
||||
"release": {},
|
||||
"repository_dispatch": {},
|
||||
"status": {},
|
||||
"watch": {},
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue