aboutsummaryrefslogtreecommitdiffstats
path: root/.github/workflows/dependabot-approve-merge.yml
blob: 6c5d73739cebe37b7a2a123a71cda00c1e4cc12d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
# This workflow is provided via the organization template repository
#
# https://github.com/nextcloud/.github
# https://docs.github.com/en/actions/learn-github-actions/sharing-workflows-with-your-organization

name: Dependabot

on:
  pull_request_target:
     branches:
      - master
      - stable*

jobs:
  auto-merge:
    runs-on: ubuntu-latest
    steps:
      # Default github action approve
      - uses: hmarr/auto-approve-action@v2
        if: github.actor == 'dependabot[bot]' || github.actor == 'dependabot-preview[bot]'
        with:
          github-token: ${{ secrets.GITHUB_TOKEN }}

      # Nextcloud bot approve and merge request
      - uses: ahmadnassri/action-dependabot-auto-merge@v2
        if: github.actor == 'dependabot[bot]' || github.actor == 'dependabot-preview[bot]'
        with:
          target: minor
          github-token: ${{ secrets.DEPENDABOT_AUTOMERGE_TOKEN }}