From a7336092ab563f34a565477cfda43e19ac3c43d3 Mon Sep 17 00:00:00 2001 From: Ankur Banerjee Date: Thu, 18 Aug 2022 22:47:41 +0100 Subject: [PATCH] Delete ensure_set_euox_pipefail.sh --- .github/scripts/ensure_set_euox_pipefail.sh | 26 --------------------- 1 file changed, 26 deletions(-) delete mode 100644 .github/scripts/ensure_set_euox_pipefail.sh diff --git a/.github/scripts/ensure_set_euox_pipefail.sh b/.github/scripts/ensure_set_euox_pipefail.sh deleted file mode 100644 index 2dd9fbfdf..000000000 --- a/.github/scripts/ensure_set_euox_pipefail.sh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/bash - -# Ensures that all bash scripts in the repository use `set -euox pipefail` or `set -euo pipefail` statement at the beginning. - -set -euo pipefail - -INVALID_FILES_FOUND=0 - -while IFS= read -r -d '' BASH_SCRIPT -do - echo "checking ${BASH_SCRIPT}" - if ( ! grep -q "set -euo pipefail" "${BASH_SCRIPT}" ) && ( ! grep -q "set -euox pipefail" "${BASH_SCRIPT}" ) - then - echo "${BASH_SCRIPT}" - INVALID_FILES_FOUND=1 - fi -done < <(find . -type f -name "*.sh" -print0) # See https://github.com/koalaman/shellcheck/wiki/SC2044 - -if [[ INVALID_FILES_FOUND -eq 1 ]] -then - echo "" - echo "The bash scripts above must include either 'set -euo pipefail' or 'set -euox pipefail." - exit 1 -else - echo "euox-pipefaile check finished successfully" -fi