Code: Select all
def forceMovie(f) {
label =~ /^(?i:Movie|Film|Concert|UFC)/ || f.dir.listPath().any{ it.name ==~ /(?i:Movies)/ } || f.isMovie()
}
def forceSeries(f) {
label =~ /^(?i:TV|Show|Series|Documentary)/ || f.dir.listPath().any{ it.name ==~ /(?i:TV.Shows)/ } || f.path =~ /(?<=\b|_)(?i:tv[sp]-|Season\D?\d{1,2}|\d{4}.S\d{2})(?=\b|_)/ || parseEpisodeNumber(f.path, true) || parseDate(f.path)
}
Ideally, you could make the tv forcing more sophisticated, too. It will not recognize having a directory named "tv" in its path.
If one of the directories in the path list is indeed "movie", "tv" or "movies" and not "atvlover38" or "movieatrix", then we know for a fact that we are matching a tv show (or a movie). There is no point catering to people that would put their tv show downloads under D:\Downloads\movies\Hahanotmovies.
With all that in mind, I think it would be a strict enhancement if that line were to be changed into detecting whether the download path contains a directory named exactly "movie", "movies" or "tv".
It's not a personal issue, as the script can easily be forked and customized. It just seemed weird that we would perform a case-senstivie check for "Movies" when checking for "movies" seems to be superior in every way.
Cheers!