diff options
author | David Eichmann <EichmannD@gmail.com> | 2019-02-15 11:34:42 +0000 |
---|---|---|
committer | David Eichmann <EichmannD@gmail.com> | 2019-02-15 11:38:41 +0000 |
commit | 14275d03cc789d702219328df280b413acbfac9e (patch) | |
tree | 29aef013091d7da8d0345302e8a0f70b8e7fc067 | |
parent | 631399414de58adaa9da9ea092e62824fd5005dc (diff) | |
download | haskell-wip/gitlab-ci-perf-notes_2.tar.gz |
checkout latest files from T-15936 MRwip/gitlab-ci-perf-notes_2
-rwxr-xr-x | .gitlab/push-test-metrics.sh | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/.gitlab/push-test-metrics.sh b/.gitlab/push-test-metrics.sh index 7ec2dfe955..302587721f 100755 --- a/.gitlab/push-test-metrics.sh +++ b/.gitlab/push-test-metrics.sh @@ -11,18 +11,20 @@ fail() { } # Check that private key is available (Set on all GitLab protected branches). -if ! [ -v PERF_NOTE_KEY ] || [ "$PERF_NOTE_KEY" = "" ]; then +if [ -z ${PERF_NOTE_KEY+"$PERF_NOTE_KEY"} ] +then echo "Not pushing performance git notes: PERF_NOTE_KEY is not set." exit 0 fi # TEST_ENV must be set. -if ! [ -v TEST_ENV ] || [ "$TEST_ENV" = "" ]; then +if [ -z ${TEST_ENV+"$TEST_ENV"} ] +then fail "Not pushing performance git notes: TEST_ENV must be set." fi # Assert that the METRICS_FILE exists and can be read. -if ! [ -v TEST_ENV ] || [ "$METRICS_FILE" = "" ] +if [ -z ${METRICS_FILE+"$METRICS_FILE"} ] then fail "\$METRICS_FILE not set." fi |