-
Notifications
You must be signed in to change notification settings - Fork 71
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[CLI Improvements] Support all
resource
#2304
Comments
There is an inconsistency here. Not all resources support the Another solution would be to merge the |
@schoren not sure that i am the best person to suggest here but i think that both solutions have their pros and cons, so it ultimately depends on specific use case and preferences. If the goal is to simplify the CLI and merge the list and get verbs, then introducing a new "get all" verb could work. This would make it consistent for all resources and avoid confusion between the list and get verbs. |
The issue currently with the config resource is that it is hard to understand how to 'get' it. If I do: So... I need to know the id. So I would naturally do: I am then 'stuck' not knowing the id for a config (it is current, but how can I know this as a new user) Solution: |
That is good, but I am getting more comfortable thinking list would make sense, even on resources that can only have 'one'. A couple reasons I think this:
I may not understand the hesitation to use the list verb when there is only one item - feel free to jump in a meeting. |
There's no "hard" reason for not supporting list in unique resources. It's just my minimalist mind trying to remove "unnecessary" things. But mainly, it was the consensus from the team. Even if adding the @kdhamric do you confirm we should have |
I would tend to definitely allow 'tracetest get config --id current' as that is how people will have been trained to get an item. I am more neutral on whether to make 'tracetest get config' work. We also need to discuss datastores, as I lot of this discussion applies to them and we may want to reconsider. |
I like @olha23's idea. If |
I like the idea of having a I don't think we should have exceptions or differences between resources. I know |
Agree with @jorgeepc here. Having identical behavior across all resources is what I'm voting for. |
Make it so... Have a list [resource] and a get [resource] --id [id] for every resource. |
Team, currently the list verb is paginated, by default we show chunks of 20 items. |
We want to support the
all
resource for verbs. It acts as a pseudo resources that actually wraps all available resources.For example, if you have configured a DataStore, a Demo, and a test, you could export them all to a yaml file like this:
you could import that dump with the following command:
Verbs supported:
get
anddelete
always require an ID, and that ID only makes sense when refering to a specific resource, so it doesn't really apply for those.The text was updated successfully, but these errors were encountered: