Skip to content

Commit

Permalink
Discord Webhook
Browse files Browse the repository at this point in the history
converted to reusable workflow with .github repo so convert this workflow to a caller workflow
  • Loading branch information
donavanbecker committed Dec 29, 2023
1 parent f1f4427 commit 293c426
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 30 deletions.
36 changes: 7 additions & 29 deletions .github/workflows/discord-webhooks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,35 +5,13 @@ name: Discord Webhooks
# Controls when the workflow will run
on:
release:
types: [released]
types: [released, prereleased]

jobs:
github-releases-to-discord:
runs-on: ubuntu-latest
name: GitHub Releases to Discord
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Latest Release
if: ${{ github.event.release.prerelease == false }}
uses: SethCohen/[email protected]
with:
webhook_url: ${{ secrets.DISCORD_WEBHOOK_URL_LATEST }}
color: "4726621"
username: "Homebridge"
avatar_url: "https://raw.githubusercontent.com/homebridge/branding/latest/logos/homebridge-color-round-stylized.png"
footer_title: "Homebridge Raspbian Image"
footer_icon_url: "https://raw.githubusercontent.com/homebridge/branding/latest/logos/homebridge-color-round-stylized.png"
footer_timestamp: true

- name: Pre-Release
if: ${{ github.event.release.prerelease == true }}
uses: SethCohen/[email protected]
with:
webhook_url: ${{ secrets.DISCORD_WEBHOOK_URL_LATEST }}
color: "4726621"
username: "Homebridge"
avatar_url: "https://raw.githubusercontent.com/homebridge/branding/latest/logos/homebridge-color-round-stylized.png"
footer_title: "Pre-Release: Homebridge Raspbian Image"
footer_icon_url: "https://raw.githubusercontent.com/homebridge/branding/latest/logos/homebridge-color-round-stylized.png"
footer_timestamp: true
uses: homebridge/.github/.github/workflows/discord-webhooks.yml@latest
with:
footer_title: "Homebridge Raspbian Image"
secrets:
DISCORD_WEBHOOK_URL_LATEST: ${{ secrets.DISCORD_WEBHOOK_URL_LATEST }}
DISCORD_WEBHOOK_URL_BETA: ${{ secrets.DISCORD_WEBHOOK_URL_LATEST }}
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,5 @@ stage1
stage2
stage3
stage4
stage5
stage5
.DS_Store

0 comments on commit 293c426

Please sign in to comment.