fix workflows

Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
This commit is contained in:
Василий Толстов 2022-03-05 18:32:28 +03:00
parent 1ee46a0aac
commit bce6f8c3e7
2 changed files with 8 additions and 8 deletions

View File

@ -1,4 +1,4 @@
name: "autoreview" name: "autoapprove"
on: on:
pull_request_target: pull_request_target:
@ -9,13 +9,13 @@ permissions:
contents: write contents: write
jobs: jobs:
dependabot: autoapprove:
runs-on: ubuntu-latest runs-on: ubuntu-latest
if: |
github.actor == 'vtolstov' ||
github.actor == 'dependabot[bot]'
steps: steps:
- name: approve - name: approve
uses: hmarr/auto-approve-action@v2
if: github.actor == 'vtolstov' || github.actor == 'dependabot[bot]'
id: approve
run: gh pr review --approve "$PR_URL" run: gh pr review --approve "$PR_URL"
env: env:
PR_URL: ${{github.event.pull_request.html_url}} PR_URL: ${{github.event.pull_request.html_url}}

View File

@ -9,10 +9,9 @@ permissions:
contents: write contents: write
jobs: jobs:
dependabot: automerge:
runs-on: ubuntu-latest runs-on: ubuntu-latest
if: | if: github.actor == 'dependabot[bot]'
github.actor == 'dependabot[bot]'
steps: steps:
- name: metadata - name: metadata
id: metadata id: metadata
@ -20,6 +19,7 @@ jobs:
with: with:
github-token: "${{ secrets.TOKEN }}" github-token: "${{ secrets.TOKEN }}"
- name: merge - name: merge
id: merge
if: ${{contains(steps.metadata.outputs.dependency-names, 'go.unistack.org')}} if: ${{contains(steps.metadata.outputs.dependency-names, 'go.unistack.org')}}
run: gh pr merge --auto --merge "$PR_URL" run: gh pr merge --auto --merge "$PR_URL"
env: env: