Update ExportVpg with help and export all option
This commit is contained in:
@@ -1,12 +1,29 @@
|
|||||||
function Export-ZertoVpg {
|
function Export-ZertoVpg {
|
||||||
[cmdletbinding()]
|
[cmdletbinding()]
|
||||||
param(
|
param(
|
||||||
[string]$outputPath,
|
[Parameter(
|
||||||
[string[]]$vpgName
|
HelpMessage = "Location where to dump the resulting JSON files containing the VPG Settings",
|
||||||
|
Mandatory = $true
|
||||||
|
)]
|
||||||
|
[string]$outputFolder,
|
||||||
|
[parameter(
|
||||||
|
HelpMessage = "Name(s) of the VPG(s) to be exported",
|
||||||
|
ParameterSetName = "namedVpgs"
|
||||||
|
)]
|
||||||
|
[string[]]$vpgName,
|
||||||
|
[parameter(
|
||||||
|
HelpMessage = "Export all VPGs at this site",
|
||||||
|
ParameterSetName = "allVpgs",
|
||||||
|
valuefrompipeline = $true,
|
||||||
|
ValueFromPipelineByPropertyName = $true
|
||||||
|
)]
|
||||||
|
[switch]$allVpgs
|
||||||
)
|
)
|
||||||
|
|
||||||
begin {
|
begin {
|
||||||
|
if ($allVpgs) {
|
||||||
|
$vpgName = $(Get-ZertoVpg).vpgName
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
process {
|
process {
|
||||||
|
|||||||
Reference in New Issue
Block a user