3
0
Fork 0
mirror of https://github.com/tj-actions/changed-files synced 2025-01-17 19:17:45 +00:00

Merge pull request #661 from tj-actions/fix/error-retrieving-the-base-sha

fix: error retrieving the base sha
This commit is contained in:
Tonye Jack 2022-10-02 04:48:40 -06:00 committed by GitHub
commit 6a459d285a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -32,7 +32,7 @@ elif [[ "$INPUT_SINCE_LAST_REMOTE_COMMIT" == "true" ]]; then
LAST_REMOTE_COMMIT=$(git rev-parse "$(git branch -r --sort=-committerdate | head -1 | xargs)")
fi
if [[ "$INPUT_SHA" == "$LAST_REMOTE_COMMIT" ]]; then
LAST_REMOTE_COMMIT=$(git rev-parse "$INPUT_SHA^1")
LAST_REMOTE_COMMIT=$(git rev-parse "$INPUT_SHA"^1)
fi
echo "::set-output name=base_sha::$LAST_REMOTE_COMMIT"
fi