Skip to content

Conversation

TheGoddessInari
Copy link
Contributor

This lets it work with both Powershell 5.x and Powershell Core 6.0.

It's not clear if Powershell 7.0 will remain compatible for other reasons.

@ras0219-msft
Copy link
Collaborator

Thanks for the PR!

Also, looks like it's available down to 3.0[1] (the earliest version listed in the docs). However, we need testing to ensure this is available for Windows 7, which iirc has 2.0 by default.

[1] https://docs.microsoft.com/en-us/powershell/module/cimcmdlets/get-ciminstance?view=powershell-3.0

@TheGoddessInari
Copy link
Contributor Author

Would it be better to have a version check for Powershell 2 and opt to fall back to use WMIObject in that case?

@Rastaban Rastaban self-assigned this Jun 11, 2019
@Rastaban
Copy link
Contributor

@TheGoddessInari that sounds good, could you add the logic to fall back for 2.0?

@Rastaban Rastaban merged commit 8cd2d17 into microsoft:master Jun 17, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants