Skip to content

Commit

Permalink
quick test
Browse files Browse the repository at this point in the history
  • Loading branch information
atavism committed Jan 21, 2025
1 parent f13dd2e commit 2df8bdf
Showing 1 changed file with 12 additions and 11 deletions.
23 changes: 12 additions & 11 deletions .github/workflows/prerelease-notification.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,19 +14,20 @@ jobs:
with:
fetch-depth: 0

- name: Generate PR Summary
id: pr-summary
run: |
REPO_URL="https://github.com/getlantern/lantern-client"
PR_SUMMARY=$(git log --since="1 week ago" --pretty=format:"%h %s" | grep -E "#[0-9]+" | sed -E 's|#([0-9]+)|[#\1]('"${REPO_URL}"'/pull/\1)|')
echo -e "PR SUMMARY: $PR_SUMMARY"
echo "::set-output name=summary::$PR_SUMMARY"
- name: Send Slack Notification
env:
SLACK_WEBHOOK_URL: ${{ secrets.LANTERN_APP_SLACK_RELEASES_WEBHOOK }}
run: |
SLACK_PAYLOAD=$(jq -n --arg text "*A new release is available!* 🚀\n\n${{ steps.pr-summary.outputs.summary }}" '{"text": $text}')
REPO_URL="https://github.com/getlantern/lantern-client"
PR_SUMMARY=$(git log --since="1 week ago" --pretty=format:"%h %s" | grep -E "#[0-9]+" | sed -E 's|#([0-9]+)|[#\1]('"${REPO_URL}"'/pull/\1)|')
SLACK_PAYLOAD=$(jq -n --arg text "*A new release is available!* 🚀\n\n$PR_SUMMARY" '{"text": $text}')
echo "Slack Payload Debug: $SLACK_PAYLOAD"
# curl -X POST -H 'Content-type: application/json' \
# --data "{\"text\":\"${SLACK_MESSAGE}\"}" $SLACK_WEBHOOK_URL
# - name: Send Slack Notification
# env:
# SLACK_WEBHOOK_URL: ${{ secrets.LANTERN_APP_SLACK_RELEASES_WEBHOOK }}
# run: |
# SLACK_PAYLOAD=$(jq -n --arg text "*A new release is available!* 🚀\n\n${{ steps.pr-summary.outputs.summary }}" '{"text": $text}')
# echo "Slack Payload Debug: $SLACK_PAYLOAD"
# # curl -X POST -H 'Content-type: application/json' \
# # --data "{\"text\":\"${SLACK_MESSAGE}\"}" $SLACK_WEBHOOK_URL

0 comments on commit 2df8bdf

Please sign in to comment.