Powershell - Module

About

Code Shipping - (Module|Component) in Powershell

Module are installed with a Powershell - Package Provider

Management

Install

Example install the credential manager module

$CREDENTIAL_MODULE_NAME='CredentialManager'
$CREDENTIAL_MANAGER = Get-Module -ListAvailable -Name $CREDENTIAL_MODULE_NAME 2>$null
if ($CREDENTIAL_MANAGER -eq $null){
    Write-Error "Credential Manager ($CREDENTIAL_MODULE_NAME) was not found. Installing it"
    Install-Module -Name $CREDENTIAL_MODULE_NAME
} else {
    Write-Host "Credential Manager ($CREDENTIAL_MODULE_NAME) is already installed."
}

Get

Get

listavailable is important !

Get-Module -Name ModuleName -ListAvailable

Version

(Get-Module -Name ModuleName -ListAvailable).Version

Powered by ComboStrap