Skip to content
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

Enhancement: Extend pp environment get to get default environment #4228

Closed
milanholemans opened this issue Dec 13, 2022 · 5 comments
Closed

Comments

@milanholemans
Copy link
Contributor

milanholemans commented Dec 13, 2022

Right now we can list all Power Platform environments or get an environment by name. It could be useful if we could just get the default environment.
We could update the command pp environment get and make the option name optional. When name is not specified, the command will return the default environment.

Options

Option Description
-n, --name [name] The name of the environment. When not specified, the default environment is retrieved.

Examples

Get the default Power Platform environment

m365 pp environment get

How to achieve

To achieve this, it seems like we should filter on the isDefault property:

image

@milanholemans milanholemans added enhancement needs peer review Needs second pair of eyes to review the spec or PR labels Dec 13, 2022
@waldekmastykarz
Copy link
Member

Great suggestion! What if specifying the name was optional and when not specified, we'd return the default environment, without introducing the --default flag?

@waldekmastykarz waldekmastykarz added needs discussion and removed needs peer review Needs second pair of eyes to review the spec or PR labels Dec 20, 2022
@milanholemans
Copy link
Contributor Author

Great suggestion! What if specifying the name was optional and when not specified, we'd return the default environment, without introducing the --default flag?

Sounds like a good idea as well, I like it!

@milanholemans
Copy link
Contributor Author

Updated the spec, thank you for the feedback!

@nanddeepn
Copy link
Contributor

Can I work on this?

@martinlingstuyl
Copy link
Contributor

Sure @nanddeepn! Thanks again!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants