From 5ff1cb2851a09978bd3aba3c5636ac645954d838 Mon Sep 17 00:00:00 2001 From: SebastianStork Date: Tue, 3 Mar 2026 17:02:42 +0100 Subject: [PATCH] workflows/ci: Notify directly after the deploy job --- .github/workflows/ci.yml | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f0a0491..d59c425 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -106,32 +106,32 @@ jobs: - name: Push to deploy branch run: git push origin HEAD:deploy --force notify-success: - if: always() && !contains(needs.*.result, 'failure') && !contains(needs.*.result, 'cancelled') - needs: [build-package, build-check, build-server, build-workstation, deploy] + if: always() && needs.deploy.result == 'success' + needs: [deploy] runs-on: ubuntu-latest steps: - name: Send ntfy success notification run: | curl -s \ - -H "Title: CI succeeded" \ + -H "Title: CI: Deploy succeeded" \ -H "Priority: low" \ -H "Tags: white_check_mark" \ -H "Actions: view, Open workflow run, ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}" \ -H "Markdown: yes" \ - -d "Commit `${{ github.sha }}` succeeded." \ + -d "Commit \`${GITHUB_SHA::7}\` deployed successfully." \ https://ntfy.sh/splitleaf notify-failure: - if: always() && contains(needs.*.result, 'failure') - needs: [build-package, build-check, build-server, build-workstation, deploy] + if: always() && needs.deploy.result != 'success' + needs: [deploy] runs-on: ubuntu-latest steps: - name: Send ntfy failure notification run: | curl -s \ - -H "Title: CI failed" \ + -H "Title: CI: Deploy failed" \ -H "Priority: default" \ -H "Tags: rotating_light" \ -H "Actions: view, Open workflow run, ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}" \ -H "Markdown: yes" \ - -d "Commit `${{ github.sha }}` failed." \ + -d "Commit \`${GITHUB_SHA::7}\` failed to deploy." \ https://ntfy.sh/splitleaf