I've been working on a rather complicated naming scheme, and would like some input on it. It works as follows...
Folders:
- - Series name in English with the Roman Japanese name in brackets (only if its different)
- Lists the year and, if available, the certification rating
- Moves "The " to the end as ", The"
- Replaces funky characters
- - Uses the English name in the episode titles
- Moves "The " to the end as ", The"
- References absolute episode number forced to 2 digits
- Shows the episode title
- finishes with the standard video format, video codec, audio codec (mainly to point out FLAC files), and audio channels
- Replaces funky characters
Ambition Of Oda Nobuna, The [Oda Nobuna no Yabou] (2012)\Ambition Of Oda Nobuna, The - 01 - Nobuna And The Monkey [720p x264 AAC 2ch]
Code: Select all
{(x = n.upperInitial().lowerTrail().replaceAll(/[`´‘’ʻ""“”]/, "'").replaceAll(/[:|]/, " - ").replaceAll(/[?]/, "!").replaceAll(/[*]/, " ").replaceAll(/[ ]/, " ").replaceFirst(/^(?i)(The)\s(.+)/, /$2, $1/))} {if (x != (z = net.sourceforge.filebot.WebServices.AniDB.animeTitles.find{n == it.getOfficialTitle('en')}?.primaryTitle ?: n.upperInitial().lowerTrail().replaceAll(/[`´‘’ʻ""“”]/, "'").replaceAll(/[:|]/, " - ").replaceAll(/[?]/, "!").replaceAll(/[*]/, " ").replaceAll(/[ ]/, " ").replaceFirst(/^(?i)(The)\s(.+)/, /$2, $1/))) "["+z.upperInitial().lowerTrail().replaceAll(/[`´‘’ʻ""“”]/, "'").replaceAll(/[:|]/, " - ").replaceAll(/[?]/, "!").replaceAll(/[*]/, " ").replaceAll(/[ ]/, " ").replaceFirst(/^(?i)(The)\s(.+)/, /$2, $1/)+"] "}({y}{" $certification"})/{n.upperInitial().lowerTrail().replaceAll(/[`´‘’ʻ""“”]/, "'").replaceAll(/[:|]/, " - ").replaceAll(/[?]/, "!").replaceAll(/[*]/, " ").replaceAll(/[ ]/, " ").replaceFirst(/^(?i)(The)\s(.+)/, /$2, $1/)} - {absolute.pad(2)}{"Special "+special.pad(2)} - {t.upperInitial().lowerTrail().replaceAll(/[`´‘’ʻ""“”]/, "'").replaceAll(/[:|]/, " - ").replaceAll(/[?]/, "!").replaceAll(/[*]/, " ").replaceAll(/[ ]/, " ")}{" ["+vf+" "+vc+" "+ac+" "+af+"]"}
Cheers,
Ithiel