Get-Metadata
SYNOPSIS
Reads a specific value from a PowerShell metadata file (e.g. a module manifest)
SYNTAX
Get-Metadata [[-Path] <String>] [[-PropertyName] <String>] [-Passthru] [<CommonParameters>]
DESCRIPTION
By default Get-Metadata gets the ModuleVersion, but it can read any key in the metadata file
EXAMPLES
EXAMPLE 1
Get-Metadata .\Configuration.psd1
Returns the module version number (as a string)
EXAMPLE 2
Get-Metadata .\Configuration.psd1 ReleaseNotes
Returns the release notes!
PARAMETERS
-Path
The path to the module manifest file
Type: System.String
Parameter Sets: (All)
Aliases: PSPath
Required: False
Position: 1
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False
-PropertyName
The property (or dotted property path) to be read from the manifest. Get-Metadata searches the Manifest root properties, and also the nested hashtable properties.
Type: System.String
Parameter Sets: (All)
Aliases:
Required: False
Position: 2
Default value: ModuleVersion
Accept pipeline input: False
Accept wildcard characters: False
-Passthru
{{ Fill Passthru Description }}
Type: System.Management.Automation.SwitchParameter
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False
CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.