mirror of
https://github.com/tj-actions/changed-files
synced 2025-01-17 19:17:45 +00:00
Merge pull request #787 from tj-actions/fix/bug-with-force-pushing-commits-to-pr-branches
This commit is contained in:
commit
991e8b3aae
1 changed files with 3 additions and 3 deletions
|
@ -198,10 +198,10 @@ else
|
|||
|
||||
if [[ -z $INPUT_BASE_SHA ]]; then
|
||||
if [[ "$INPUT_SINCE_LAST_REMOTE_COMMIT" == "true" ]]; then
|
||||
PREVIOUS_SHA=""
|
||||
PREVIOUS_SHA=$GITHUB_EVENT_BEFORE
|
||||
|
||||
if [[ "$GITHUB_EVENT_FORCED" == "false" || -z "$GITHUB_EVENT_FORCED" ]]; then
|
||||
PREVIOUS_SHA=$GITHUB_EVENT_BEFORE
|
||||
if ! git rev-parse --quiet --verify "$PREVIOUS_SHA^{commit}" 1>/dev/null 2>&1; then
|
||||
PREVIOUS_SHA=$(git rev-list -n 1 "$TARGET_BRANCH" 2>&1) && exit_status=$? || exit_status=$?
|
||||
fi
|
||||
|
||||
if [[ -z "$PREVIOUS_SHA" || "$PREVIOUS_SHA" == "0000000000000000000000000000000000000000" ]]; then
|
||||
|
|
Loading…
Reference in a new issue