mirror of
https://github.com/tj-actions/changed-files
synced 2025-02-19 15:23:42 +00:00
fix: bug with last remote commit sha
This commit is contained in:
parent
cc8c5e7787
commit
e3b5eb746a
1 changed files with 4 additions and 1 deletions
|
@ -165,7 +165,10 @@ runs:
|
|||
elif [[ -n "${{ inputs.base_sha }}" ]]; then
|
||||
echo "::set-output name=base_sha::${{ inputs.base_sha }}"
|
||||
elif [[ "${{ inputs.since_last_remote_commit }}" == "true" ]]; then
|
||||
LAST_REMOTE_COMMIT=$(git rev-parse $(git branch -r --sort=-committerdate | head -1))
|
||||
LAST_REMOTE_COMMIT="${{ github.event.before }}"
|
||||
if [[ -z "$LAST_REMOTE_COMMIT" ]]; then
|
||||
LAST_REMOTE_COMMIT=$(git rev-parse $(git branch -r --sort=-committerdate | head -1))
|
||||
fi
|
||||
if [[ "${{ inputs.sha }}" == "$LAST_REMOTE_COMMIT" ]]; then
|
||||
LAST_REMOTE_COMMIT=$(git rev-parse "${{ inputs.sha }}^1")
|
||||
fi
|
||||
|
|
Loading…
Add table
Reference in a new issue