selectRunEnvironments selects multiple environments for use in an untenanted run
(ask question.Asker, octopus *octopusApiClient.Client, space *spaces.Space, project *projects.Project, runbook *runbooks.Runbook, gitRef string)
| 1223 | |
| 1224 | // selectRunEnvironments selects multiple environments for use in an untenanted run |
| 1225 | func selectGitRunEnvironments(ask question.Asker, octopus *octopusApiClient.Client, space *spaces.Space, project *projects.Project, runbook *runbooks.Runbook, gitRef string) ([]*environments.Environment, error) { |
| 1226 | envs, err := runbooks.ListEnvironmentsForGitRunbook(octopus, space.ID, project.ID, runbook.ID, gitRef) |
| 1227 | if err != nil { |
| 1228 | return nil, err |
| 1229 | } |
| 1230 | |
| 1231 | return question.MultiSelectMap(ask, "Select one or more environments", envs, func(p *environments.Environment) string { |
| 1232 | return p.Name |
| 1233 | }, true) |
| 1234 | } |
| 1235 | |
| 1236 | func PrintAdvancedSummary(stdout io.Writer, options *executor.TaskOptionsRunbookRunBase) { |
| 1237 | runAtStr := "Now" |
no test coverage detected