mirror of
https://github.com/HSLdevcom/digitransit-ui
synced 2025-07-07 02:30:36 +02:00
7 lines
340 B
Bash
Executable file
7 lines
340 B
Bash
Executable file
#!/bin/bash
|
|
set -e
|
|
|
|
if [ -n "${SLACK_CHANNEL_ID}" ]; then
|
|
MSG='{"channel": "'$SLACK_CHANNEL_ID'","text":"'"${PUBLISHED_PACKAGES}"'\n", "username": "NPM publisher"}'
|
|
curl -X POST -H 'Content-Type: application/json' -H "Authorization: Bearer $SLACK_ACCESS_TOKEN" -H 'Accept: */*' -d "$MSG" 'https://slack.com/api/chat.postMessage'
|
|
fi
|