Skip to content

Commit

Permalink
优化脚本
Browse files Browse the repository at this point in the history
  • Loading branch information
yaming116 committed Jun 8, 2024
1 parent 1b6ecda commit 9b44387
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 3 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/docker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,10 @@ jobs:
sh pull.sh
data=`cat trigger.txt`
if [-z $MM_NOTIFY_URL ];then
echo 'MM_NOTIFY_URL not set'
else
if [ $MM_NOTIFY_URL ];then
curl -H 'Content-Type: application/json' \
-d "{\"msgtype\": \"text\",\"text\": {\"content\":\"同步成功 $data \"}}" \
$MM_NOTIFY_URL
else
echo 'MM_NOTIFY_URL not set'
fi
10 changes: 10 additions & 0 deletions test.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@

MM_NOTIFY_URL=""
data=`cat trigger.txt`
if [ $MM_NOTIFY_URL ];then
curl -H 'Content-Type: application/json' \
-d "{\"msgtype\": \"text\",\"text\": {\"content\":\"同步成功 $data \"}}" \
$MM_NOTIFY_URL
else
echo 'MM_NOTIFY_URL not set'
fi

0 comments on commit 9b44387

Please sign in to comment.