diff options
-rw-r--r-- | .github/workflows/clippy.yml | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/.github/workflows/clippy.yml b/.github/workflows/clippy.yml index a708f5b..840e0aa 100644 --- a/.github/workflows/clippy.yml +++ b/.github/workflows/clippy.yml @@ -9,8 +9,13 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 + if: github.event_name == 'pull_request_target' with: - ref: ${{ github.head_ref || github.ref }} + ref: refs/pull/${{ github.event.number }}/head + - uses: actions/checkout@v2 + if: github.event_name != 'pull_request_target' + with: + ref: ${{ github.head_ref }} - uses: actions-rs/toolchain@v1 with: profile: minimal |