microsoft / appcenter-cli

Command-line Interface (CLI) for Visual Studio App Center
https://appcenter.ms/
MIT License
581 stars 234 forks source link

App should not be required when adding users to a distribution group via CLI #1050

Closed lbrownell-gpsw closed 3 months ago

lbrownell-gpsw commented 4 years ago

When adding (or presumably removing) users to a distribution group via the CLI, one is required to include an app.

The app has no practical consequence in this matter -- you're just adding users to a group, who will gain access to all the builds added to that group for all the apps it includes. And the help shows it as optional:

Usage: appcenter distribute groups update -g|--group [-D|--delete-testers-file ] [-T|--add-testers-file ] [-d|--delete-testers ] [-t|--add-testers ] [-n|--name ] [-a|--app ]

It makes one wonder if this uncovers a hidden "feature" in App Center, where you can segregate users into only seeing some (or one -- you can only specify one, unless you can repeat the -a parameter) apps within the distribution group. But, then again, hard to know, as there is little documentation.

Thanks.

anywherepilot commented 4 years ago

Documentation for distribution groups is here: https://docs.microsoft.com/en-us/appcenter/distribution/groups

lbrownell-gpsw commented 3 years ago

@anywherepilot yes, thanks, I wasn't precise in my documentation complaint, it's about the CLI, not about distribution groups.

Shouldn't this have some sort of label about CLI, since that's where the problem lies?

EDIT: And wow, I didn't mention CLI in the title! Just added it. Apologies.

anywherepilot commented 3 years ago

This entire repo is only for CLI related issues. If we find something is not a problem with the CLI, we ask to move the issue to the main App Center repo. So no need to mention CLI, and no CLI labels here :)

Just in trying to understand your issue I thought you may be missing some information about how distribution groups work, that's why I linked the doc, since there's hardly any doc in the CLI itself.

Distribution groups are part of an app, unless you create a shared distribution group in an org. The org support in the CLI is very limited. It appears the distribution groups the CLI can deal with are only the ones that are part of an app, hence the requirement to add an app name.

The help text generation system isn't able to handle the parameters which are common to all commands well, such as app, which is why it shows up as optional while it really isn't.

lbrownell-gpsw commented 3 years ago

Thanks for the explanation. We only use shared distribution groups, but...even in single-app distribution groups, aren't their names also unique across the organization? Didn't see that in the documentation, but apparently not, and they need the app (and org, specified as part of the app) to clarify it.

I don't expect you to re-work the CLI and break everyone else's scripts, but you could've had the group id include org/app/group or just org/group if shared. Too late now. Unless there is some sensible way to avoid my gripe that won't break other users, feel free to close this.

In any case, it works, I just to add any of the apps in the group to the command.

DmitriyKirakosyan commented 3 months ago

Closing as stale.