Skip to content

正则表达式,可以提供,语法参考功能吗? #172

正则表达式,可以提供,语法参考功能吗?

正则表达式,可以提供,语法参考功能吗? #172

Workflow file for this run

name: Issue and Discussions Trigger
on:
issues:
types: [opened]
discussion:
types: [created]
jobs:
send_message:
runs-on: ubuntu-latest
steps:
- name: Send message
run: |
generate_post_data(){
text="有新的 Discussion"
if [ ${{ github.event_name }} == "issues" ]; then
text="有新的 Issue"
fi
cat <<EOF
{
"msg_type": "text",
"content": {
"text": "$text"
}
}
EOF
}
curl -X POST -H "Content-Type: application/json" \
-d "$(generate_post_data)" \
https://open.feishu.cn/open-apis/bot/v2/hook/${{ secrets.FEISHU_BOT_WEBHOOK_URL }}