From 3e93e27f7230c61cc3c5086dc5bd3ab5c57cf133 Mon Sep 17 00:00:00 2001 From: Marvin Flock Date: Thu, 4 Sep 2025 22:02:39 +0200 Subject: [PATCH] chore: add notification to teams --- .github/workflows/build_release.yml | 21 +++++++++++++++++ .github/workflows/teams_integration.yml | 30 ------------------------- 2 files changed, 21 insertions(+), 30 deletions(-) delete mode 100644 .github/workflows/teams_integration.yml diff --git a/.github/workflows/build_release.yml b/.github/workflows/build_release.yml index b76747f..c60c21d 100644 --- a/.github/workflows/build_release.yml +++ b/.github/workflows/build_release.yml @@ -98,3 +98,24 @@ jobs: else echo "No draft releases found" fi + + - name: Send notification to Teams + run: | + curl -H 'Content-Type: application/json' \ + -d "{ + \"@type\": \"MessageCard\", + \"@context\": \"http://schema.org/extensions\", + \"summary\": \"New Release\", + \"themeColor\": \"0076D7\", + \"title\": \"🚀 New Release: ${{ github.event.release.name }}\", + \"sections\": [{ + \"activityTitle\": \"Version ${{ github.event.release.tag_name }}\", + \"text\": \"${{ github.event.release.body }}\" + }], + \"potentialAction\": [{ + \"@type\": \"OpenUri\", + \"name\": \"View Release\", + \"targets\": [{ \"os\": \"default\", \"uri\": \"${{ github.event.release.html_url }}\" }] + }] + }" \ + ${{ secrets.TEAMS_WEBHOOK_URL }} diff --git a/.github/workflows/teams_integration.yml b/.github/workflows/teams_integration.yml deleted file mode 100644 index 4aa4294..0000000 --- a/.github/workflows/teams_integration.yml +++ /dev/null @@ -1,30 +0,0 @@ -name: Notify Teams on Release - -on: - release: - types: [published] - -jobs: - notify: - runs-on: ubuntu-latest - steps: - - name: Send notification to Teams - run: | - curl -H 'Content-Type: application/json' \ - -d "{ - \"@type\": \"MessageCard\", - \"@context\": \"http://schema.org/extensions\", - \"summary\": \"New Release\", - \"themeColor\": \"0076D7\", - \"title\": \"🚀 New Release: ${{ github.event.release.name }}\", - \"sections\": [{ - \"activityTitle\": \"Version ${{ github.event.release.tag_name }}\", - \"text\": \"${{ github.event.release.body }}\" - }], - \"potentialAction\": [{ - \"@type\": \"OpenUri\", - \"name\": \"View Release\", - \"targets\": [{ \"os\": \"default\", \"uri\": \"${{ github.event.release.html_url }}\" }] - }] - }" \ - ${{ secrets.TEAMS_WEBHOOK_URL }}