File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -174,7 +174,7 @@ function Add-Parameter {
174174 }
175175
176176 Write-Debug " Existing parameters: $ ( $Ast.Parameters.Name -join ' , ' ) "
177- $global :ParameterSource = $this.ParameterSource
177+ # $global:ParameterSource = $this.ParameterSource
178178 $Additional = $this.ParameterSource.Parameters.Where { $_.Name -notin ([string []]$Ast.Parameters.Name ) }
179179 Write-Debug " Additional parameters from boilerplate: $ ( $Additional.Count ) "
180180 if (($Text = $Additional.Text -join " ,`n`n " )) {
Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ function Update-AliasesToExport {
1010
1111 This function never outputs any TextReplacements
1212 #>
13- [CmdletBinding ()]
13+ [CmdletBinding (SupportsShouldProcess )]
1414 [OutputType ([TextReplacement ])]
1515 param (
1616 # The AST of the root script module to find aliases in
@@ -143,7 +143,7 @@ function Update-AliasesToExport {
143143 process {
144144 $Visitor = [AliasExportGenerator ]::new()
145145 $ScriptModule.Visit ($Visitor )
146- Update-Metadata - Path $ModuleManifest - PropertyName AliasesToExport - Value $Visitor.Aliases
146+ Update-Metadata - Path $ModuleManifest - PropertyName AliasesToExport - Value $Visitor.Aliases - WhatIf: $WhatIfPreference - Confirm:( $ConfirmPreference -eq ' Low ' )
147147 }
148148}
149149
You can’t perform that action at this time.
0 commit comments