From b4b4b40c0326a9b4133323aab631f5971c996c16 Mon Sep 17 00:00:00 2001 From: Tonye Jack Date: Thu, 3 Nov 2022 12:32:34 -0600 Subject: [PATCH] Updated diff-sha.sh --- diff-sha.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/diff-sha.sh b/diff-sha.sh index a99be2a1..41f6fed8 100644 --- a/diff-sha.sh +++ b/diff-sha.sh @@ -53,10 +53,10 @@ if [[ -z $GITHUB_BASE_REF ]]; then exit 1 fi else - git fetch --no-tags -u --progress --depth="$INPUT_FETCH_DEPTH" origin "$TARGET_BRANCH":"$TARGET_BRANCH" if [[ -z $INPUT_SHA ]]; then CURRENT_SHA=$(git rev-list --no-merges -n 1 HEAD 2>&1) && exit_status=$? || exit_status=$? else + git fetch --no-tags -u --progress --depth="$INPUT_FETCH_DEPTH" origin "$TARGET_BRANCH":"$TARGET_BRANCH" CURRENT_SHA=$INPUT_SHA; exit_status=$? fi fi