-
Notifications
You must be signed in to change notification settings - Fork 181
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Co-authored-by: Tibor Blenessy <[email protected]>
- Loading branch information
1 parent
a8e28ef
commit 3444def
Showing
1 changed file
with
42 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
name: sonar-release | ||
# This workflow is triggered when publishing a new github release | ||
on: | ||
release: | ||
types: | ||
- published | ||
|
||
env: | ||
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} | ||
|
||
jobs: | ||
sonar_release: | ||
runs-on: ubuntu-latest | ||
name: Start release process | ||
steps: | ||
- name: Checkout release action | ||
uses: actions/checkout@v2 | ||
with: | ||
repository: SonarSource/gh-action_LT_release | ||
|
||
- name: LT release | ||
id: lt_release | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }} | ||
# Put your action repo here | ||
uses: SonarSource/gh-action_LT_release@master | ||
|
||
- name: Check outputs | ||
if: always() | ||
run: | | ||
echo "${{ steps.lt_release.outputs.releasability }}" | ||
echo "${{ steps.lt_release.outputs.release }}" | ||
#slack notifications | ||
- name: Notify success on Slack | ||
uses: Ilshidur/[email protected] | ||
with: | ||
args: "Release successful for {{ GITHUB_REPOSITORY }} by {{ GITHUB_ACTOR }}" | ||
- name: Notify failures on Slack | ||
uses: Ilshidur/[email protected] | ||
if: failure() | ||
with: | ||
args: "Release failed, see the logs at https://github.com/{{ GITHUB_REPOSITORY }}/actions by {{ GITHUB_ACTOR }}" |