fix: bug running on pull_request_review (#915)
This commit is contained in:
parent
4ca6f666de
commit
dbfd5e10a7
6
.github/workflows/test.yml
vendored
6
.github/workflows/test.yml
vendored
@ -12,9 +12,9 @@ on:
|
|||||||
- reopened
|
- reopened
|
||||||
branches:
|
branches:
|
||||||
- main
|
- main
|
||||||
# pull_request_review
|
pull_request_review:
|
||||||
# branches:
|
branches:
|
||||||
# - main
|
- main
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
shellcheck:
|
shellcheck:
|
||||||
|
@ -182,8 +182,8 @@ runs:
|
|||||||
GITHUB_REPOSITORY: ${{ github.repository }}
|
GITHUB_REPOSITORY: ${{ github.repository }}
|
||||||
GITHUB_REF: ${{ github.ref }}
|
GITHUB_REF: ${{ github.ref }}
|
||||||
GITHUB_SHA: ${{ github.sha }}
|
GITHUB_SHA: ${{ github.sha }}
|
||||||
GITHUB_BASE_REF: ${{ github.base_ref }}
|
GITHUB_BASE_REF: ${{ github.event.pull_request.base.ref }}
|
||||||
GITHUB_HEAD_REF: ${{ github.head_ref }}
|
GITHUB_HEAD_REF: ${{ github.event.pull_request.head.ref }}
|
||||||
GITHUB_WORKSPACE: ${{ github.workspace }}
|
GITHUB_WORKSPACE: ${{ github.workspace }}
|
||||||
GITHUB_EVENT_NUMBER: ${{ github.event.number }}
|
GITHUB_EVENT_NUMBER: ${{ github.event.number }}
|
||||||
GITHUB_EVENT_HEAD_REPO_FORK: ${{ github.event.pull_request.head.repo.fork }}
|
GITHUB_EVENT_HEAD_REPO_FORK: ${{ github.event.pull_request.head.repo.fork }}
|
||||||
@ -226,7 +226,7 @@ runs:
|
|||||||
shell: bash
|
shell: bash
|
||||||
env:
|
env:
|
||||||
GITHUB_WORKSPACE: ${{ github.workspace }}
|
GITHUB_WORKSPACE: ${{ github.workspace }}
|
||||||
GITHUB_BASE_REF: ${{ github.base_ref }}
|
GITHUB_BASE_REF: ${{ github.event.pull_request.base.ref }}
|
||||||
GITHUB_EVENT_HEAD_REPO_FORK: ${{ github.event.pull_request.head.repo.fork }}
|
GITHUB_EVENT_HEAD_REPO_FORK: ${{ github.event.pull_request.head.repo.fork }}
|
||||||
# INPUT_<VARIABLE_NAME> is not available in Composite run steps
|
# INPUT_<VARIABLE_NAME> is not available in Composite run steps
|
||||||
# https://docs.github.com/en/actions/creating-actions/metadata-syntax-for-github-actions#example-specifying-inputs
|
# https://docs.github.com/en/actions/creating-actions/metadata-syntax-for-github-actions#example-specifying-inputs
|
||||||
|
@ -50,6 +50,8 @@ else
|
|||||||
echo "Valid git version found: ($GIT_VERSION)"
|
echo "Valid git version found: ($GIT_VERSION)"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
echo "Base Ref: $GITHUB_BASE_REF"
|
||||||
|
|
||||||
if [[ -z $GITHUB_BASE_REF ]]; then
|
if [[ -z $GITHUB_BASE_REF ]]; then
|
||||||
echo "Running on a push event..."
|
echo "Running on a push event..."
|
||||||
TARGET_BRANCH=$GITHUB_REFNAME
|
TARGET_BRANCH=$GITHUB_REFNAME
|
||||||
|
Loading…
x
Reference in New Issue
Block a user