Skip to content

Commit 5585e36

Browse files
Add logging for environment variables to capture RUNNER_* values
1 parent 982038e commit 5585e36

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

scripts/main.ps1

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,19 @@ process {
115115
Get-Content -Path $env:GITHUB_STATE
116116
}
117117

118+
LogGroup ' - Environment Variables' {
119+
$props = @{}
120+
121+
Get-ChildItem Env: | Where-Object { $_.Name -like 'RUNNER_*' } | ForEach-Object {
122+
$props[$_.Name] = $_.Value
123+
}
124+
125+
$customObject = [PSCustomObject]$props
126+
127+
$customObject | Format-List
128+
}
129+
130+
118131
Write-Output '┗━━━━━━━━━━━━━━━━━━━━━━━━━━━┛'
119132

120133
} catch {

0 commit comments

Comments
 (0)