Skip to content

fix: 更新 tgmShare 群 ID 为正确的值 #41

fix: 更新 tgmShare 群 ID 为正确的值

fix: 更新 tgmShare 群 ID 为正确的值 #41

Workflow file for this run

name: Notify Telegram on GitHub Push
description: 'Send notifications to Telegram groups (topics) and channel on push to main branch'
on:
push:
branches:
- main
jobs:
notify:
runs-on: ubuntu-latest
steps:
- name: Send notification to tgmShare group topic 5
env:
BOT_TOKEN: ${{ secrets.BOT_TOKEN }}
run: |
TEXT="📝 新增资源\n\n${{ github.event.head_commit.message }}\n\n🔗 超过100T资料总站网站:https://doc.869hr.uk\n📦 完整资源链接:https://t.me/dabaziyuan"
curl -s -X POST "https://api.telegram.org/bot${BOT_TOKEN}/sendMessage" \
-d chat_id="-1002573762160" \
-d message_thread_id="5" \
-d parse_mode="Markdown" \
--data-urlencode "text=${TEXT}"
- name: Send notification to tgmShareAI group topic 2
env:
BOT_TOKEN: ${{ secrets.BOT_TOKEN }}
run: |
TEXT="📝 新增资源\n\n${{ github.event.head_commit.message }}\n\n🔗 超过100T资料总站网站:https://doc.869hr.uk\n📦 完整资源链接:https://t.me/dabaziyuan"
curl -s -X POST "https://api.telegram.org/bot${BOT_TOKEN}/sendMessage" \
-d chat_id="-1003365897434" \
-d message_thread_id="2" \
-d parse_mode="Markdown" \
--data-urlencode "text=${TEXT}"
- name: Send full content to Telegram channel
env:
BOT_TOKEN: ${{ secrets.BOT_TOKEN }}
CHANNEL_ID: ${{ secrets.TELEGRAM_CHANNEL_ID }}
run: |
if [ -n "$CHANNEL_ID" ]; then
TEXT="📦 新增资源推送\n\n${{ github.event.head_commit.message }}\n\n🔗 超过100T资料总站网站:https://doc.869hr.uk\n📂 查看详情:${{ github.event.head_commit.url }}"
curl -s -X POST "https://api.telegram.org/bot${BOT_TOKEN}/sendMessage" \
-d chat_id="$CHANNEL_ID" \
-d parse_mode="Markdown" \
--data-urlencode "text=${TEXT}"
fi