Don't allow test-format.sh to be run locally
This commit is contained in:

committed by
NeroBurner

parent
443408312a
commit
a6fcdec0f8
@@ -2,11 +2,13 @@
|
||||
|
||||
set -e
|
||||
|
||||
[ -z "$1" ] && exit
|
||||
if [ -z "$GITHUB_BASE_REF" ]
|
||||
then
|
||||
echo "This script is only meant to be run in a GitHub Workflow"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
basebranch=$1
|
||||
|
||||
CHANGED_FILES=$(git diff --name-only "$basebranch"...HEAD)
|
||||
CHANGED_FILES=$(git diff --name-only "$GITHUB_BASE_REF"...HEAD)
|
||||
|
||||
CHANGED=0
|
||||
|
||||
|
Reference in New Issue
Block a user