diff --git a/.github/workflows/auto-wait-successful.yml b/.github/workflows/auto-wait-successful.yml index a185221c3..06a0d0f91 100644 --- a/.github/workflows/auto-wait-successful.yml +++ b/.github/workflows/auto-wait-successful.yml @@ -3,17 +3,25 @@ name: 🤖 Auto approve when success on: workflow_run: workflows: ['⚙️ Build demo', '⚙️ Build lib', '⚙️ Lint', '⚙️ Tests'] - branches-ignore: [main] - types: [completed] + types: + - completed jobs: on-success: runs-on: ubuntu-latest - if: ${{ github.event.workflow_run.conclusion == 'success' }} + if: ${{ github.event.workflow_run.conclusion == 'success' && github.ref != 'refs/heads/main' }} steps: - run: echo 'The triggering workflow passed' + - uses: taiga-family/ci/actions/setup/checkout@v1.23.0 + - uses: taiga-family/ci/actions/setup/variables@v1.23.0 + - uses: taiga-family/ci/actions/auto/approve/double@v1.23.0 + if: env.TAIGA_FAMILY_BOT_IS_AUTHOR == 'true' + with: + token1: ${{ secrets.GITHUB_TOKEN }} + token2: ${{ secrets.TAIGA_FAMILY_APPROVE_BOT_PAT }} + on-failure: runs-on: ubuntu-latest - if: ${{ github.event.workflow_run.conclusion == 'failure' }} + if: ${{ github.event.workflow_run.conclusion == 'failure' && github.ref != 'refs/heads/main' }} steps: - run: echo 'The triggering workflow failed'