features icon indicating copy to clipboard operation
features copied to clipboard

Support specifying PowerShell Module Version

Open russellds opened this issue 1 year ago • 1 comments

It would be extremely helpful if you could specify the version of the PowerShell module(s) to be installed. There are times where I need a specific version, typically with the Azure PowerShell module, because of issues with the latest version.

A simple way to do it would be to seperate the module and version with a colon, see below. If the version is not specified, then install the latest as it currently works.

"ghcr.io/devcontainers/features/powershell:1": {
      "version": "latest",
      "modules": "powershell-yaml,Az:11.4.0"
    }

russellds avatar May 08 '24 14:05 russellds

Hi 👋

The request makes sense to me and I like the suggested approach of using the : delimiter ; adding this item to the backlog!

@russellds if you are interested, feel free to open a PR with the proposed changes. We appreciate community contributions and I'm happy to help with the reviews 🙏

samruddhikhandale avatar May 09 '24 00:05 samruddhikhandale

Hi @samruddhikhandale ,

I have created the PR for this fix here: https://github.com/devcontainers/features/pull/993 kindly review and approve the same if it satisfies the user requirements

prathameshzarkar9 avatar Jun 03 '24 20:06 prathameshzarkar9

Hi @samruddhikhandale ,

Addressed review comments on the PR and also added a test case to verify the specified Powershell module version is installed successfully.

prathameshzarkar9 avatar Jun 10 '24 06:06 prathameshzarkar9