Skip to content

Commit 10434f3

Browse files
Rename parameter in Install-PSModule function for clarity and consistency
1 parent aca15d2 commit 10434f3

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

scripts/Helpers/Helpers.psm1

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -300,16 +300,16 @@ function Install-PSModule {
300300
param(
301301
# Path to the folder where the module source code is located.
302302
[Parameter(Mandatory)]
303-
[string] $ModulePath
303+
[string] $Path
304304
)
305305

306-
$moduleName = Split-Path -Path $ModulePath -Leaf
307-
$manifestFilePath = Join-Path -Path $ModulePath "$moduleName.psd1"
306+
$moduleName = Split-Path -Path $Path -Leaf
307+
$manifestFilePath = Join-Path -Path $Path "$moduleName.psd1"
308308
Write-Verbose " - Manifest file path: [$manifestFilePath]" -Verbose
309309
Resolve-PSModuleDependency -ManifestFilePath $manifestFilePath
310310
$PSModulePath = $env:PSModulePath -split [System.IO.Path]::PathSeparator | Select-Object -First 1
311311
$codePath = New-Item -Path "$PSModulePath/$moduleName/999.0.0" -ItemType Directory -Force | Select-Object -ExpandProperty FullName
312-
Copy-Item -Path "$ModulePath/*" -Destination $codePath -Recurse -Force
312+
Copy-Item -Path "$Path/*" -Destination $codePath -Recurse -Force
313313
LogGroup 'Importing module' {
314314
Import-Module -Name $moduleName -Verbose
315315
}

0 commit comments

Comments
 (0)