1
0
Fork 0

introduce editions and other minor refinements

This commit is contained in:
Xavier Fontanet 2024-09-14 13:17:24 +02:00
parent 3ea98d4d1e
commit 39355729f1
3 changed files with 30 additions and 18 deletions

View File

@ -52,6 +52,15 @@ def countAudiosInMap(audMap){
for (aud in audMap) count += aud.value.size() for (aud in audMap) count += aud.value.size()
return count return count
} }
def getEdition (fileName) {
def pre = '{edition-'
def post = '}'
return fileName.find(/(?i)\bV\.Ext(endida)?\b|\bversi.n.ext\b/) != null ? pre+'Versión Extendida'+post :
fileName.find(/(?i)\bver\..dir(ector)?\b/) != null ? (pre+'Versión Director'+post) :
fileName.find(/\b(r|R)emas[a-z]*\b/) != null ? (pre+'Remasterizada'+post) :
fileName.find(/(?i)\bproper\b|\brepack\b/) != null ? (pre+'Versión corregida'+post) :
''
}
/********* SUBS ***************/ /********* SUBS ***************/
def handleSub(sub, capturedSubs) { def handleSub(sub, capturedSubs) {
def lang = sub.Language_String3 !=null ? sub.Language_String3 def lang = sub.Language_String3 !=null ? sub.Language_String3

View File

@ -1,4 +1,6 @@
/** Tipo de archivo incorrecto **/ /** Tipo de archivo incorrecto **/
def isOnlyRelocate = {try{only_relocate} catch(e){false}}()
if (!isOnlyRelocate) {
if (ext==~/jpg|nfo|png|url/) { if (ext==~/jpg|nfo|png|url/) {
return fn return fn
} }
@ -17,6 +19,7 @@ try {
} catch (err) { } catch (err) {
throw new Exception("[genero_no_especificado]") throw new Exception("[genero_no_especificado]")
} }
}
//*** Relocate Remux and UHD to Transcode input folder //*** Relocate Remux and UHD to Transcode input folder
def peso = bytes.toString().before(' ').toDouble() def peso = bytes.toString().before(' ').toDouble()

View File

@ -35,7 +35,7 @@
if (formato_distribucion=='WEB-DL') { if (formato_distribucion=='WEB-DL') {
def plataforma = fn.find( //coge el contenido que encaja def plataforma = fn.find( //coge el contenido que encaja
/(?i)\bAMZN?\b|\bNF\b|\bHBO\b|\bHBO.?MAX\b|\bHMAX\b|\bHULU\b|\bA3P\b|\bDPLY\b|\bSTARZ\b|\bFILMIN\b|\bFLMN\b|\bNETFLIX\b|\bDSN.?\b|\bDSP+?\b|\bRTVE\b|\bFLIXOL.\b|(?<!\w)M\+(?!\w)|\bSKYSHO\b|\bAPTV\b|\bATVP\b/ ) /(?i)\bAMZN?\b|\bNF\b|\bHBO\b|\bHBO.?MAX\b|\bHMAX\b|\bMAX\b|\bHULU\b|\bA3P\b|\bDPLY\b|\bSTARZ\b|\bFILMIN\b|\bFLMN\b|\bNETFLIX\b|\bDSN.?\b|\bDSP+?\b|\bRTVE\b|\bFLIXOL.\b|(?<!\w)M\+(?!\w)|\bSKYSHO\b|\bAPTV\b|\bATVP\b/ )
if (plataforma!=null) { if (plataforma!=null) {
plataforma = plataforma.toUpperCase() plataforma = plataforma.toUpperCase()
.replace("MVPLUS","MV+").replace("DSNY","DSN+").replace("ATVP","APTV+") .replace("MVPLUS","MV+").replace("DSNY","DSN+").replace("ATVP","APTV+")