From f4df34e67cbd90ca9ac7f00c3bf863c78a35dbcf Mon Sep 17 00:00:00 2001 From: Binit Shah Date: Thu, 10 Oct 2024 12:00:37 -0400 Subject: [PATCH] Fix pre-commit GH Action not running on PR updates (#107) See https://github.com/reviewdog/action-eslint/issues/29#issuecomment-985939887 for an explanation on how to filter out draft PRs. Co-authored-by: hello-vinitha <145490650+hello-vinitha@users.noreply.github.com> --- .github/workflows/pre-commit.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/pre-commit.yaml b/.github/workflows/pre-commit.yaml index 87a33c8..b181274 100644 --- a/.github/workflows/pre-commit.yaml +++ b/.github/workflows/pre-commit.yaml @@ -6,7 +6,7 @@ on: - main - master pull_request: - types: [review_requested, ready_for_review] + types: [opened, reopened, synchronize, review_requested, ready_for_review] workflow_dispatch: concurrency: @@ -19,6 +19,7 @@ env: jobs: pre-commit: runs-on: ubuntu-latest + if: ${{ !github.event.pull_request.draft }} steps: - uses: actions/checkout@v4 - uses: actions/setup-python@v5