diff --git a/.github/workflows/linters.yml b/.github/workflows/linters.yml index a690144e53..faa028f01f 100644 --- a/.github/workflows/linters.yml +++ b/.github/workflows/linters.yml @@ -96,3 +96,16 @@ jobs: pip install pip-audit cd ${GITHUB_WORKSPACE} pip-audit --desc on . + + precommit: + name: 'Pre-Commit' + runs-on: ubuntu-latest + if: github.event_name == 'pull_request' + + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 + with: + python-version: '3.10' + cache: pip + - uses: pre-commit/action@v3.0.1 diff --git a/.github/workflows/pre-commit.yml b/.github/workflows/pre-commit.yml deleted file mode 100644 index bfc29812e4..0000000000 --- a/.github/workflows/pre-commit.yml +++ /dev/null @@ -1,26 +0,0 @@ -name: Pre-commit - -on: - pull_request: - workflow_dispatch: - -permissions: - contents: read - -concurrency: - group: precommit-frappe-${{ github.event_name }}-${{ github.event.number }} - cancel-in-progress: true - -jobs: - linter: - name: 'precommit' - runs-on: ubuntu-latest - if: github.event_name == 'pull_request' - - steps: - - uses: actions/checkout@v4 - - uses: actions/setup-python@v5 - with: - python-version: '3.10' - cache: pip - - uses: pre-commit/action@v3.0.1