Skip to content

Commit fb80802

Browse files
committed
fix: trying to fix release action
1 parent 3b30ebb commit fb80802

File tree

1 file changed

+10
-6
lines changed

1 file changed

+10
-6
lines changed

.github/workflows/release.yml

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -42,16 +42,20 @@ jobs:
4242
env:
4343
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4444

45+
- name: Set Discord embed color based on release type
46+
id: set_color
47+
run: |
48+
if [[ "${GITHUB_REF##*/}" == *-* ]]; then
49+
echo "color=d29922" >> $GITHUB_OUTPUT
50+
else
51+
echo "color=3eb991" >> $GITHUB_OUTPUT
52+
fi
53+
4554
- name: GitHub Releases to Discord
4655
uses: SethCohen/github-releases-to-discord@v1
4756
with:
4857
webhook_url: ${{ secrets.WEBHOOK_URL }}
49-
color: |
50-
if [[ "${GITHUB_REF##*/}" == *-* ]]; then
51-
echo "color=d29922"
52-
else
53-
echo "color=3eb991"
54-
fi
58+
color: ${{ steps.set_color.outputs.color }}
5559
content: "<@&1394740955000606902>"
5660
footer_title: "github-actions"
5761
reduce_headings: true

0 commit comments

Comments
 (0)