ps/Modules/Alkami.PowerShell.Choco/Public/Test-IsPackagePowerShellModule.ps1
2023-05-30 22:51:22 -07:00

20 lines
431 B
PowerShell

function Test-IsPackagePowerShellModule {
<#
.SYNOPSIS
Returns true if a particular package is considered a PowerShell module.
#>
[CmdletBinding()]
[OutputType([System.Boolean])]
Param (
[Parameter(Mandatory=$true)]
[string]$packageName
)
foreach($match in $_PowerShellModulePackages) {
if($packageName -like $match) {
return $true;
}
}
return $false;
}