MCPcopy Create free account
hub / github.com/github/gh-aw / expandLabelCommandShorthand

Function expandLabelCommandShorthand

pkg/workflow/label_command_parser.go:13–19  ·  view source on GitHub ↗

expandLabelCommandShorthand takes a label name and returns a map that represents the expanded label_command + workflow_dispatch configuration. This is the intermediate form stored in the frontmatter "on" map before parseOnSection processes it into WorkflowData.LabelCommand.

(labelName string)

Source from the content-addressed store, hash-verified

11// This is the intermediate form stored in the frontmatter "on" map before
12// parseOnSection processes it into WorkflowData.LabelCommand.
13func expandLabelCommandShorthand(labelName string) map[string]any {
14 labelCommandParserLog.Printf("Expanding label-command shorthand for label: %s", labelName)
15 return map[string]any{
16 "label_command": labelName,
17 "workflow_dispatch": nil,
18 }
19}

Callers 2

Calls 1

PrintfMethod · 0.45

Tested by 1