File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ name : CI
2+
3+ on :
4+ push :
5+ branches : [master]
6+ pull_request :
7+ branches : [master]
8+ workflow_dispatch :
9+
10+ jobs :
11+ powershell-module-static-smoke :
12+ runs-on : ubuntu-latest
13+
14+ steps :
15+ - name : Checkout
16+ uses : actions/checkout@v4
17+
18+ - name : Parse PowerShell module files
19+ shell : pwsh
20+ run : |
21+ $targets = @(
22+ './PSFeedHandler/PSFeedHandler.psd1',
23+ './PSFeedHandler/PSFeedHandler.psm1'
24+ )
25+
26+ foreach ($path in $targets) {
27+ $parseErrors = $null
28+ $tokens = $null
29+ [void][System.Management.Automation.Language.Parser]::ParseFile((Resolve-Path $path), [ref]$tokens, [ref]$parseErrors)
30+ if ($parseErrors.Count -gt 0) {
31+ $parseErrors | ForEach-Object { Write-Error ("{0}: {1}" -f $path, $_.Message) }
32+ exit 1
33+ }
34+ }
35+
36+ Write-Host 'PSFeedHandler static PowerShell parse checks passed.'
37+
38+ # Intentionally lightweight:
39+ # - validates the module manifest and main module file parse cleanly
40+ # - avoids fake network/feed-runtime claims in default CI
You can’t perform that action at this time.
0 commit comments