Skip to content
This repository has been archived by the owner on Oct 4, 2024. It is now read-only.

Commit

Permalink
chore: update
Browse files Browse the repository at this point in the history
  • Loading branch information
splincode committed Oct 5, 2023
1 parent 46ef483 commit 4d57e13
Showing 1 changed file with 36 additions and 6 deletions.
42 changes: 36 additions & 6 deletions .github/workflows/auto-approve.yml
Original file line number Diff line number Diff line change
@@ -1,16 +1,46 @@
name: 🤖 Auto approve by bot
name: 🤖 Auto approve validation
on: pull_request

env:
JOBS_NAME: '[ "ci" ]'

jobs:
automated-pull-request:
setup:
runs-on: ubuntu-latest
permissions:
pull-requests: write
outputs:
matrix: ${{ steps.matrix.outputs.value }}
steps:
- uses: actions/checkout@v4.1.0
- uses: taiga-family/ci/actions/setup/checkout@v1.24.1
- uses: taiga-family/ci/actions/setup/[email protected]
- uses: taiga-family/ci/actions/auto/approve/[email protected]
- id: matrix
if: env.TAIGA_FAMILY_BOT_IS_AUTHOR == 'true'
run: echo "value=$JOBS_NAME" >> $GITHUB_OUTPUT

wait:
needs: [setup]
runs-on: ubuntu-latest
strategy:
fail-fast: true
matrix:
value: ${{ fromJSON(needs.setup.outputs.matrix) }}
steps:
- uses: taiga-family/ci/actions/run/[email protected]
with:
token: ${{ secrets.GITHUB_TOKEN }}
job: ${{ matrix.value }}

approve:
needs: [wait]
runs-on: ubuntu-latest
steps:
- uses: taiga-family/ci/actions/auto/approve/[email protected]
with:
token1: ${{ secrets.GITHUB_TOKEN }}
token2: ${{ secrets.TAIGA_FAMILY_APPROVE_BOT_PAT }}
- uses: taiga-family/ci/actions/run/[email protected]
with:
token: ${{ secrets.TAIGA_FAMILY_APPROVE_BOT_PAT }}

concurrency:
group: auto-approve-${{ github.head_ref }}
cancel-in-progress: true

0 comments on commit 4d57e13

Please sign in to comment.