diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 613f4e55..3962ef12 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -53,24 +53,32 @@ jobs: - name: Check uncommitted unformatted code run: | ./lint-format.sh - - name: Slack Notification - if: success() - uses: rtCamp/action-slack-notify@v2 - env: - SLACK_CHANNEL: sora-ios-sdk - SLACK_COLOR: good - SLACK_TITLE: SUCCEEDED - SLACK_ICON_EMOJI: ":star-struck:" - SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} - - name: Slack Notification - if: failure() - uses: rtCamp/action-slack-notify@v2 - env: - SLACK_CHANNEL: sora-ios-sdk - SLACK_COLOR: danger - SLACK_TITLE: "FAILED" - SLACK_ICON_EMOJI: ":japanese_ogre:" - SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} + slack_notify_succeeded: + needs: [build] + runs-on: ubuntu-latest + if: success() + steps: + - name: Slack Notification + uses: rtCamp/action-slack-notify@v2 + env: + SLACK_CHANNEL: sora-ios-sdk + SLACK_COLOR: good + SLACK_TITLE: SUCCEEDED + SLACK_ICON_EMOJI: ":star-struck:" + SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} + slack_notify_failed: + needs: [build] + runs-on: ubuntu-latest + if: failure() + steps: + - name: Slack Notification + uses: rtCamp/action-slack-notify@v2 + env: + SLACK_CHANNEL: sora-ios-sdk + SLACK_COLOR: danger + SLACK_TITLE: "FAILED" + SLACK_ICON_EMOJI: ":japanese_ogre:" + SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} release: if: contains(github.ref, 'tags/v') needs: [build]