http://livestreamer.tanuki.se/en/latest/
Very very thankful for this tool, I search for something like this sense I hooked on StarCraft II!
To use script, just edit configuration part... It's pretty self explanatory.
In my time zone, all GSL battles going when I'm at work.
This script allows me to record all and watch it when I come back home after work! :)
I use livesreamer, not only for recording. Sorry, but Twitch page is lagging and I don't need other stuff, only video. And the best experience, in sense of avoiding video lagging or some sort of interrupts, is to stream to file and then watch it!
Also you can start streaming to file and watch from the file right away. Perhaps you should wait 10 or 15 seconds, this way player not going to catch the end of the file!
^^^^^^^^^^^^^^^^^^^^^^^^^^
#! /bin/bash
STREAM_URL="http://www.twitch.tv/gsl"
STREAM_QUALITY="best"
STREAMS_DUMP_DIR="/media/xbmc/Streams/"
STREAM_FILE_NAME="gsl_code_s_"
# month day year hour minutes
START_TIMESTAMP=$(date -d '10/04/2014 11:45' +%s)
END_TIMESTAMP=$(date -d '10/04/2014 19:00' +%s)
KILL_TIMESTAMP=$(date -d '10/04/2014 19:01' +%s)
^^^^^^^^^^^^^^^^^^^^^^^^^^
Bash version1
Bash version 2
It runs as a daemon. Just drop a simple text file to "shed" directory.
Text file should look like this:
^^^^^^^^^^^^^^^^^^^^^^^^^^
# twitch link
URL=http://www.twitch.tv/nathanias
# Year Month Day
DATE=2014.12.23
# Hours minutes
TIME=07.45
^^^^^^^^^^^^^^^^^^^^^^^^^^Also set global configurations before start ("bash.conf"):
^^^^^^^^^^^^^^^^^^^^^^^^^^
# stream quality
QUALITY=best
# directory where steams will be saved
DIR=/media/8b58Volume830GiB/Streams/
# stream offline timeout to consider that stream is ended.
# at least one stream file should be created
# in minutes
OFFLINE_TIMEOUT=20
^^^^^^^^^^^^^^^^^^^^^^^^^^
Extract archive and open terminal in "livestreamer-deamon" directory
$ ./livestreamer-deamon start
I run this on Raspberry-Pi. I can leave it online 24for7 it consumes ~5W of power and make no noise! It's environment friendly and wife approved! :)))
I added this to /etc/rc.local
^^^^^^^^^^^^^^^^^^^^^^^^^^
# livestreamer-deamon
cd /home/pi/wcs/
su pi /home/pi/wcs/livestreamer-deamon.bash start >> /dev/null 2>> /dev/null &
^^^^^^^^^^^^^^^^^^^^^^^^^^Bash version 3
^^^^^^^^^^^^^^^^^^^^^^^^^^
# twitch link
URL=http://www.twitch.tv/nathanias
# Year Month Day
DATE=2015.04.04
# Hours minutes
TIME=19.34
# Continue for ? days and record everything...
DAYS=3
# log file
LOG=
^^^^^^^^^^^^^^^^^^^^^^^^^^If days set to zero it will work as before.
Download :
livestreamer-bash
Enjoy!