Skip to content

Commit

Permalink
fix(pipeline/exec): Output one pipeline execution after exec. (#130)
Browse files Browse the repository at this point in the history
  • Loading branch information
jtk54 authored Feb 19, 2019
1 parent eb2d365 commit 889bce1
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions cmd/pipeline/execute.go
Original file line number Diff line number Diff line change
Expand Up @@ -114,10 +114,10 @@ func executePipeline(cmd *cobra.Command, options ExecuteOptions) error {
return fmt.Errorf("Unable to start any executions, server response was: %v", resp)
}

refIds := make([]string, 0)
for _, execution := range executions {
refIds = append(refIds, execution.(map[string]interface{})["id"].(string))
if len(executions) > 1 {
return fmt.Errorf("Started more than one execution: %v", executions)
}
util.UI.Output(fmt.Sprintf("%v", refIds))

util.UI.JsonOutput(executions[0], util.UI.OutputFormat)
return nil
}

0 comments on commit 889bce1

Please sign in to comment.