added latest changes.
This commit is contained in:
@@ -23,3 +23,8 @@ jobs:
|
|||||||
VALIDATE_JSON: true
|
VALIDATE_JSON: true
|
||||||
VALIDATE_MD: true
|
VALIDATE_MD: true
|
||||||
DEFAULT_BRANCH: ${{ github.base_ref }}
|
DEFAULT_BRANCH: ${{ github.base_ref }}
|
||||||
|
|
||||||
|
- name: Checking shebang lines in MacOS and Ubuntu releases.
|
||||||
|
shell: powershell
|
||||||
|
run: |
|
||||||
|
./images.CI/shebang-linter.ps1
|
||||||
|
|||||||
@@ -24,8 +24,8 @@ function Validate-Scripts {
|
|||||||
$PathUbuntu = "./images/linux/scripts"
|
$PathUbuntu = "./images/linux/scripts"
|
||||||
$PathMacOS = "./images/macos/provision"
|
$PathMacOS = "./images/macos/provision"
|
||||||
$ScriptsWithBrokenShebang = @()
|
$ScriptsWithBrokenShebang = @()
|
||||||
$ScriptsWithBrokenShebang += Validate-Scripts -Path $PathUbuntu -Pattern "#!/bin/bash -e"
|
$ScriptsWithBrokenShebang += Validate-Scripts -Path $PathUbuntu -ExpectedShebang "#!/bin/bash -e"
|
||||||
$ScriptsWithBrokenShebang += Validate-Scripts -Path $PathMacOS -Pattern "#!/bin/bash -e -o pipefail"
|
$ScriptsWithBrokenShebang += Validate-Scripts -Path $PathMacOS -ExpectedShebang "#!/bin/bash -e -o pipefail"
|
||||||
if ($ScriptsWithBrokenShebang.Length -gt 0) {
|
if ($ScriptsWithBrokenShebang.Length -gt 0) {
|
||||||
$ScriptsWithBrokenShebang | ForEach-Object {
|
$ScriptsWithBrokenShebang | ForEach-Object {
|
||||||
Write-Warning "The following script does not contain shebang: '$_'"
|
Write-Warning "The following script does not contain shebang: '$_'"
|
||||||
|
|||||||
Reference in New Issue
Block a user