From 0e8bd858c306398c1684685e2fbdc210987f6b34 Mon Sep 17 00:00:00 2001 From: Reinhard Pointner Date: Sat, 13 Apr 2013 06:47:28 +0000 Subject: [PATCH] * fixes for better handling of oddly named archives and help auto-detection along by putting the original folder ahead of the archive name @see http://www.filebot.net/forums/viewtopic.php?f=8&t=666&p=4443#p4443 --- website/scripts/amc.groovy | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/website/scripts/amc.groovy b/website/scripts/amc.groovy index 44cf039c..7f70688e 100644 --- a/website/scripts/amc.groovy +++ b/website/scripts/amc.groovy @@ -86,8 +86,8 @@ input = input.flatten() def tempFiles = [] input = input.flatten{ f -> if (f.isArchive() || f.hasExtension('001')) { - def extractDir = new File(f.parentFile, f.nameWithoutExtension) - def extractFiles = extract(file: f, output: extractDir, conflict: 'override', filter: { it.isArchive() || it.isVideo() || it.isSubtitle() || (music && it.isAudio()) }, forceExtractAll: true) ?: [] + def extractDir = new File(f.dir, f.nameWithoutExtension) + def extractFiles = extract(file: f, output: new File(extractDir, f.dir.name), conflict: 'override', filter: { it.isArchive() || it.isVideo() || it.isSubtitle() || (music && it.isAudio()) }, forceExtractAll: true) ?: [] tempFiles += extractDir tempFiles += extractFiles return extractFiles