Last active
July 28, 2016 18:23
-
-
Save haxwithaxe/43033136032d5da301380af2393a3a1d to your computer and use it in GitHub Desktop.
download all the things
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
URL_BASE="http://livestream.com/internetsociety" #"/hopeconf" | |
VIDEO_TYPE="progressive_url" | |
touch lamarr noether friedman | |
dump_track(){ | |
wget -O - "http://livestream.com/internetsociety${1}/hopeconf" 2>/dev/null| sed 's/","/",\n"/g' | grep $VIDEO_TYPE | grep -v smil | sed 's/[",]\+$//;s/.*"//' | grep http | |
} | |
for url in $(dump_track | tee lamarr.new); do | |
grep -q "${url}" lamarr && wget "${url}" | |
done | |
mv lamarr.new lamarr | |
for url in $(dump_track 2 | tee noether.new); do | |
grep -q "${url}" noether && wget "${url}" | |
done | |
mv noether.new noether | |
for url in $(dump_track 3 | tee friedman.new); do | |
grep -q "${url}" friedman && wget "${url}" | |
done | |
mv friedman.new friedman |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment