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

Take module version into account for -SaveDscDependency switch #1094

Merged

Conversation

bergmeister
Copy link
Collaborator

@bergmeister bergmeister commented Nov 5, 2018

PR Summary

Fixes #1079 and removes some old dead code.
This is a minimum viable implementation so that we cater for the version as well. It can parse now e.g. Import-DscResource -ModuleName MyModuleName -ModuleVersion 1.2.3.4, before it could not handle the ModuleVersion parameter.
It does not cover cases when not using named parameters or the parameter sets where multiple modules are being used or the (rather old) form of the module specification syntax (e.g. –ModuleName @{ModuleName="xPSDesiredStateConfiguration";ModuleVersion="8.3.0.0"}

PR Checklist

@bergmeister bergmeister added this to the 1.18 milestone Nov 5, 2018
@bergmeister bergmeister changed the title WIP Take module version into account for -SaveDscDependency switch Take module version into account for -SaveDscDependency switch Nov 5, 2018
@bergmeister bergmeister requested review from kapilmb and JamesWTruher and removed request for kapilmb November 5, 2018 21:05
Copy link
Member

@JamesWTruher JamesWTruher left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@bergmeister bergmeister merged commit 888139b into PowerShell:development Dec 11, 2018
bergmeister added a commit to bergmeister/PSScriptAnalyzer that referenced this pull request Mar 22, 2019
…Shell#1094)

* Take module version into account for SaveDscDependency and remove old dead code

* fix tests and add test case
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

SaveDscDependency switch does not work when Import-DscResource specifies ModuleVersion
2 participants