Skip to content

Commit

Permalink
add condition for the COMMIT_DATE environment variable
Browse files Browse the repository at this point in the history
  • Loading branch information
cz-help committed May 10, 2021
1 parent 73c848d commit 1c5e9a4
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tools/perf-test/perf-test-process.sh
Expand Up @@ -38,7 +38,8 @@ else
GIT_COMMIT=$(basename $TGZFILE | cut -d- -f5 | cut -d. -f1)
fi

COMMIT_DATE=$(git show -s --format=%cI "${GIT_COMMIT}")
# check for commit date in case the date is not already set
: "${COMMIT_DATE:=$(git show -s --format=%cI "${GIT_COMMIT}")}"

# load to DB
BUILD_ID=$(psql -tc "select id from mst_build where commit_hash='${GIT_COMMIT}'")
Expand Down

0 comments on commit 1c5e9a4

Please sign in to comment.