ci: enable automerge for generated PRs

Signed-off-by: Jens Langhammer <jens.langhammer@beryju.org>
This commit is contained in:
Jens Langhammer 2021-11-23 19:15:31 +01:00
parent 27d109c1fe
commit aa64cf898f
2 changed files with 18 additions and 0 deletions

View file

@ -37,10 +37,19 @@ jobs:
run: pipenv run ./manage.py compilemessages run: pipenv run ./manage.py compilemessages
- name: Create Pull Request - name: Create Pull Request
uses: peter-evans/create-pull-request@v3 uses: peter-evans/create-pull-request@v3
id: cpr
with: with:
token: ${{ secrets.GITHUB_TOKEN }} token: ${{ secrets.GITHUB_TOKEN }}
branch: compile-backend-translation branch: compile-backend-translation
commit-message: "core: compile backend translations" commit-message: "core: compile backend translations"
title: "core: compile backend translations" title: "core: compile backend translations"
body: "core: compile backend translations"
delete-branch: true delete-branch: true
signoff: true signoff: true
- name: Enable Pull Request Automerge
if: steps.cpr.outputs.pull-request-operation == 'created'
uses: peter-evans/enable-pull-request-automerge@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
pull-request-number: ${{ steps.cpr.outputs.pull-request-number }}
merge-method: squash

View file

@ -30,10 +30,19 @@ jobs:
npm i @goauthentik/api@$VERSION npm i @goauthentik/api@$VERSION
- name: Create Pull Request - name: Create Pull Request
uses: peter-evans/create-pull-request@v3 uses: peter-evans/create-pull-request@v3
id: cpr
with: with:
token: ${{ secrets.GITHUB_TOKEN }} token: ${{ secrets.GITHUB_TOKEN }}
branch: update-web-api-client branch: update-web-api-client
commit-message: "web: Update Web API Client version" commit-message: "web: Update Web API Client version"
title: "web: Update Web API Client version" title: "web: Update Web API Client version"
body: "web: Update Web API Client version"
delete-branch: true delete-branch: true
signoff: true signoff: true
- name: Enable Pull Request Automerge
if: steps.cpr.outputs.pull-request-operation == 'created'
uses: peter-evans/enable-pull-request-automerge@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
pull-request-number: ${{ steps.cpr.outputs.pull-request-number }}
merge-method: squash