Created
October 28, 2012 23:26
-
-
Save XayOn/3970424 to your computer and use it in GitHub Desktop.
Play the lastest file in a serie
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
# My dir structure is like this: | |
# Series name/ | |
# Season X/ | |
# Chapter | |
# So, this script get a random series and plays the lastest chapter | |
# This way, flexget gets all the tv series from me, and this command plays randomly the lastest chapter. | |
# Soon I'll add something like a read flag, or I'll check out the last file access, if last file access < 7 days, a new chapter is probably there! | |
a=(*); mplayer "$(find ${a[ $[ ( $RANDOM % ${#a[@]} ) + 1 ] - 1 ]}/*|tail -n1)" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment