filebot/website/scripts/sorteps.groovy

13 lines
445 B
Groovy
Raw Normal View History

2012-03-10 10:47:39 +00:00
def dir = 'E:/Downloads'
// extract files from archives and delete archives afterwards
extract(folder:dir, output:dir) && dir.listFiles{ it =~ /rar$/ }*.delete()
getMissingSubtitles(folder:dir, lang:'de', strict:false)
getMissingSubtitles(folder:dir, lang:'en', strict:false)
// rename each file individually in strict mode
dir.listFiles().each {
rename(file:it, format:"E:/Series/{n}/{n.space('.')}.{s00e00}.{t.space('.')}", strict:true)
}