Skip to content

update IPTV list

update IPTV list #2

Workflow file for this run

name: update IPTV list
on:
watch:
types: started
schedule:
- cron: "00 0 * * *"
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Set git identity
run : |
git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com"
git config --global user.name "github-actions[bot]"
sudo timedatectl set-timezone "Asia/Shanghai"
- name: Update
run: |
# IPTV-v4
rm -f IPTV-v4.m3u && wget https://raw.githubusercontent.com/fanmingming/live/main/tv/m3u/index.m3u -O IPTV-v4.m3u
sed -i -n '/group-title/,+1p' IPTV-v4.m3u
sed -i '1i #EXTM3U' IPTV-v4.m3u
sed -i '/^\s*$/d' IPTV-v4.m3u
# IPTV-v6
rm -f IPTV-v6.m3u && wget https://raw.githubusercontent.com/fanmingming/live/main/tv/m3u/ipv6.m3u -O IPTV-v6.m3u
sed -i -n '/group-title/,+1p' IPTV-v6.m3u
sed -i '1i #EXTM3U' IPTV-v6.m3u
sed -i '/^\s*$/d' IPTV-v6.m3u
# Global
rm -f Global.m3u && wget https://raw.githubusercontent.com/YueChan/Live/main/Global.m3u -O Global.m3u
sed -i -n '/group-title/,+1p' Global.m3u
sed -i '1i #EXTM3U' Global.m3u
sed -i '/^\s*$/d' Global.m3u
# IPTV整合源
rm -f IPTV.m3u && touch IPTV.m3u
sed 's/group-title="/group-title="IPv4·/g' IPTV-v4.m3u && cat IPTV-v4.m3u >> IPTV.m3u
sed 's/group-title="/group-title="IPv6·/g' IPTV-v6.m3u && cat IPTV-v6.m3u >> IPTV.m3u
cat Global.m3u >> IPTV.m3u
sed -i '/#EXTM3U/d' IPTV.m3u
sed -i '1i #EXTM3U' IPTV.m3u
sed -i '/^\s*$/d' IPTV.m3u
rm -f IPTV-v4.m3u
rm -f IPTV-v6.m3u
rm -f Global.m3u
# 节目源
rm -f EPG.xml && wget https://epg.112114.xyz/pp.xml -O EPG.xml
- name: Apply
run: |
Emoji=("🎉" "🤞" "✨" "🎁" "🎈" "🎄" "🎨" "💋" "🍓" "🍕" "🍉" "💐" "🌴" "🚀" "🛸" "🗽" "⛅" "🌈" "🔥" "⛄" "🐶" "🏅" "🦄" "🐤")
git add .
git commit -m "${Emoji[$[$RANDOM % ${#Emoji[@]}]]} Sync $(date +%Y-%m-%d" "%H:%M:%S)"
git push -f