Added ability to specify multiple services top be opened with the --console flag #827
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What changed?
Altered the services flag to now be a string slice flag which accepts multiple services (ie
assume -c -s s3 -s rds
) Which will then open up the console with two tabs one for each of the services.To do this I altered the logic for creating URLs to now create a list of URL's even when just creating one.
It then loops through all urls created and runs the same browser logic previously used.
Why?
I've been learning vim and have been looking for simple tasks to complete on Granted :D
For #807
How did you test it?
Manually testing
assume -c
with and without the -s flag for one and multiple servicesRunning related commands like
assume --url
assume
granted console
to confirm no regressions madePotential risks
string -> stringSlice flag should have no usage changes but all code paths using .String() need to have been changed to ensure correct logic
Altering logic in the assume command has the potential to create regressions in some of the flags logic.
It might be worth noting here that the
assume.go
file is becoming quite complicated due to small additions over time and could use with a refactor to simplify it down. This would be a big task but could be useful to minimise any regressions being added.Is patch release candidate?
Link to relevant docs PRs