diff --git a/.github/workflows/autofix.yml b/.github/workflows/autofix.yml index ca6e59c..836a28f 100644 --- a/.github/workflows/autofix.yml +++ b/.github/workflows/autofix.yml @@ -24,4 +24,4 @@ jobs: - run: ncc build index.js env: NODE_OPTIONS: "--openssl-legacy-provider" - - uses: autofix-ci/action@551dded8c6cc8a1054039c8bc0b8b48c51dfc6ef + - uses: autofix-ci/action@2891949f3779a1cafafae1523058501de3d4e944 # v1.3.1 diff --git a/.github/workflows/automerge.yml b/.github/workflows/automerge.yml new file mode 100644 index 0000000..775abc2 --- /dev/null +++ b/.github/workflows/automerge.yml @@ -0,0 +1,18 @@ +# Adapted from MNE-Python +name: Bot auto-merge +on: pull_request # yamllint disable-line rule:truthy + +jobs: + autobot: + permissions: + contents: write + pull-requests: write + runs-on: ubuntu-latest + # Names can be found with gh api /repos/mne-tools/mne-python/pulls/12998 -q .user.login for example + if: (github.event.pull_request.user.login == 'dependabot[bot]' || github.event.pull_request.user.login == 'pre-commit-ci[bot]' || github.event.pull_request.user.login == 'github-actions[bot]') && github.repository == 'scientific-python/circleci-artifacts-redirector-action' + steps: + - name: Enable auto-merge for bot PRs + run: gh pr merge --auto --squash "$PR_URL" + env: + PR_URL: ${{github.event.pull_request.html_url}} + GH_TOKEN: ${{secrets.GITHUB_TOKEN}}