Skip to content

Instantly share code, notes, and snippets.

@dardo82
Last active March 28, 2016 06:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dardo82/29935c66f68c2cedffef to your computer and use it in GitHub Desktop.
Save dardo82/29935c66f68c2cedffef to your computer and use it in GitHub Desktop.
Rec TVL stream
#!/bin/zsh
MM3U8="live-04.viewer.dacast.com/i/dclive_1@104057/master.m3u8"
TJSON="http://services.dacast.com/token/i/b/28193/c/34004.json"
TOKEN="$(print $(curl -s "$TJSON" | awk -F'["]' '{print $6}'))"
IM3U8="$(curl -s "$MM3U8""$TOKEN" | awk '/m3u8/')"
TSSEG="$(curl -s "$IM3U8" | awk '/ts/{match($0,/([0-9]+)_/,a);\
sub(/([0-9]+)_/,"["a[1]"-"a[1]+9"]_");print $0;exit}')"
curl --limit-rate 100k "$TSSEG" >> tvl.ts
@dardo82
Copy link
Author

dardo82 commented Jan 7, 2016

Scarica da TVL un minuto di trasmissione in formato TS.
http://www.tvl.it/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment