Skip to content

Commit

Permalink
Updated determining the remote sha
Browse files Browse the repository at this point in the history
  • Loading branch information
jackton1 committed Sep 25, 2022
1 parent 3d7cff9 commit bc7fa5e
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions diff-sha.sh
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,12 @@ if [[ -z $GITHUB_BASE_REF ]]; then
fi

if [[ "$PREVIOUS_SHA" == "$CURRENT_SHA" ]]; then
INITIAL_COMMIT="true"
echo "::debug::Initial commit detected"
PREVIOUS_SHA=$(git rev-parse "$CURRENT_SHA^1")

if [[ "$PREVIOUS_SHA" == "$CURRENT_SHA" ]]; then
INITIAL_COMMIT="true"
echo "::debug::Initial commit detected"
fi
fi
else
PREVIOUS_SHA=$INPUT_BASE_SHA
Expand Down

0 comments on commit bc7fa5e

Please sign in to comment.