ci(lint): update PSScriptAnalyzer invocation to use custom settings file
This commit is contained in:
@@ -44,10 +44,11 @@ jobs:
|
||||
Install-Module PSScriptAnalyzer -Scope CurrentUser -Force -AllowClobber
|
||||
}
|
||||
|
||||
$paths = @('scripts', 'template', 'runner', 'Setup-Host.ps1')
|
||||
$settings = Join-Path $PWD 'PSScriptAnalyzerSettings.psd1'
|
||||
$paths = @('scripts', 'template', 'Setup-Host.ps1')
|
||||
$results = $paths | ForEach-Object {
|
||||
if (Test-Path $_) {
|
||||
Invoke-ScriptAnalyzer -Path $_ -Recurse -Severity Error,Warning
|
||||
Invoke-ScriptAnalyzer -Path $_ -Recurse -Settings $settings -Severity Error,Warning
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user