mirror of
https://github.com/actions/runner-images-sangeeth.git
synced 2026-01-05 01:31:51 +08:00
added comments
This commit is contained in:
@@ -26,8 +26,10 @@ function Validate-Scripts {
|
||||
}
|
||||
|
||||
$ScriptsWithBrokenShebang = @()
|
||||
# Check Ubuntu contains required shebang string
|
||||
$ScriptsWithBrokenShebang += Validate-Scripts -Path $path1 -Pattern "#!/bin/bash -e"
|
||||
$ScriptsWithBrokenShebang += Validate-Scripts -Path $path2 -Pattern "#!/bin/bash -e"
|
||||
# Check MacOS contains required shebang string
|
||||
$ScriptsWithBrokenShebang += Validate-Scripts -Path $path2 -Pattern "#!/bin/bash -e -o pipefail"
|
||||
if ($ScriptsWithBrokenShebang.Length -gt 0) {
|
||||
$ScriptsWithBrokenShebang | ForEach-Object {
|
||||
Write-Warning "The following script does not contain shebang: '$_'"
|
||||
|
||||
Reference in New Issue
Block a user