Share pipeline invocation preparation
This commit is contained in:
@@ -60,6 +60,10 @@ func runFlags() []commandkit.Flag[pipelineRunInput] {
|
||||
return append(flags, executionOverrideFlags(func(input *pipelineRunInput) *executionOverrides { return &input.Overrides })...)
|
||||
}
|
||||
|
||||
func pipelineRunArguments() []commandkit.Argument[pipelineRunInput] {
|
||||
return []commandkit.Argument[pipelineRunInput]{commandkit.ValueArgument(commandkit.ArgumentMeta{Name: "pipeline-id", Usage: "Configured pipeline identifier."}, true, parseRequiredRunValue, func(input *pipelineRunInput, value commandkit.Supplied[string]) { input.PipelineID = value.Value })}
|
||||
}
|
||||
|
||||
func parseRequiredRunValue(value string) (string, error) {
|
||||
if strings.TrimSpace(value) == "" {
|
||||
return "", fmt.Errorf("value must not be empty")
|
||||
|
||||
Reference in New Issue
Block a user