mirror of
https://github.com/ivabus/pantry
synced 2024-11-22 08:25:07 +03:00
Notify Discord about new pkgs
This commit is contained in:
parent
f866ade524
commit
7ab565fc39
1 changed files with 22 additions and 0 deletions
22
.github/workflows/cd.yml
vendored
22
.github/workflows/cd.yml
vendored
|
@ -37,3 +37,25 @@ jobs:
|
|||
with:
|
||||
projects: ${{ needs.ingest.outputs.projects }}
|
||||
secrets: inherit
|
||||
|
||||
notify:
|
||||
needs: [pkg, ingest]
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: make embeds
|
||||
id: make-embeds
|
||||
run: |
|
||||
RV=""
|
||||
for x in ${{ needs.ingest.outputs.projects }}; do
|
||||
RV="${RV:+$RV,} {\"title\": \"$x\", \"url\": \"https://pkgx.dev/pkgs/$x\"}"
|
||||
done
|
||||
echo "json=$RV" >> $GITHUB_OUTPUT
|
||||
- uses: Ilshidur/action-discord@0.3.2
|
||||
env:
|
||||
DISCORD_EMBEDS: |
|
||||
{
|
||||
"embeds": [${{ steps.make-embeds.outputs.json }}]
|
||||
}
|
||||
DISCORD_WEBHOOK: ${{ secrets.DISCORD_WEBHOOK }}
|
||||
with:
|
||||
args: new pkgs
|
||||
|
|
Loading…
Reference in a new issue