annotate bin/ren @ 77:fef22522dca3

[cek.pl] better comment
author Edho Prima Arief <me@myconan.net>
date Sun, 19 Jun 2011 02:06:16 +0700
parents babf62f1bba7
children 428c308e609d 34f193d5e7cd
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
4
94ee419ad047 Added bin-ec - a collection of scripts.
Edho Prima Arief <me@myconan.net>
parents:
diff changeset
1 #!/usr/bin/env perl
94ee419ad047 Added bin-ec - a collection of scripts.
Edho Prima Arief <me@myconan.net>
parents:
diff changeset
2
94ee419ad047 Added bin-ec - a collection of scripts.
Edho Prima Arief <me@myconan.net>
parents:
diff changeset
3 use warnings;
94ee419ad047 Added bin-ec - a collection of scripts.
Edho Prima Arief <me@myconan.net>
parents:
diff changeset
4 use strict;
94ee419ad047 Added bin-ec - a collection of scripts.
Edho Prima Arief <me@myconan.net>
parents:
diff changeset
5 use File::Basename;
94ee419ad047 Added bin-ec - a collection of scripts.
Edho Prima Arief <me@myconan.net>
parents:
diff changeset
6
94ee419ad047 Added bin-ec - a collection of scripts.
Edho Prima Arief <me@myconan.net>
parents:
diff changeset
7 my @files = @ARGV or print("Usage: ",basename($0)," file1 ... fileN\n") && exit(1);
94ee419ad047 Added bin-ec - a collection of scripts.
Edho Prima Arief <me@myconan.net>
parents:
diff changeset
8 my $skip=0;
94ee419ad047 Added bin-ec - a collection of scripts.
Edho Prima Arief <me@myconan.net>
parents:
diff changeset
9 foreach (@files) {
36
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
10 print(qq(Could not find file "$_", skipping\n)) and next() unless -e $_;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
11 my $newname = $_;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
12 #START HERE
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
13 $newname =~ s/_/ /g;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
14 #TITLE AND NAMES
41
9a0cbfe1195b [ren] More rules
Edho Prima Arief <me@myconan.net>
parents: 36
diff changeset
15 $newname =~ s/^\[Jumonji-Giri\]\[Soldats\]\[AonE&HQA\] D\.C\. Da Capo /[Jumonji-Giri] Da Capo /i;
36
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
16 $newname =~ s/^PitaTen.* Ep (\d+) .*\.avi/[Hnk] Pita Ten - $1.avi/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
17 $newname =~ s/^\[a-S\] Inuyasha - (\d+|\d+-\d+) /Inuyasha - $1 [a-S]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
18 $newname =~ s/\[DVD\]\[AHQ\]/[AHQ][DVD]/;
70
babf62f1bba7 [ren] subdesu desu~
Edho Prima Arief <me@myconan.net>
parents: 41
diff changeset
19 $newname =~ s/\[subdesu\]/[SubDesu]/i;
babf62f1bba7 [ren] subdesu desu~
Edho Prima Arief <me@myconan.net>
parents: 41
diff changeset
20 $newname =~ s/ Zettai Shougeki - Platonic Heart / Zettai Shougeki /i;
36
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
21 $newname =~ s/^mars daybreak /[V-A] Mars Daybreak - /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
22 $newname =~ s/ Shuffle! Episode / Shuffle! /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
23 $newname =~ s/^\[ZA\]\.Saint\.Seiya\.Episode\.(\d+)\.DVDrip\.\[X264\.AAC\(Jpn-Fre\)\.Sub\(Fre-Eng\)\.Chap\]\.mkv$/[D-YFI] Saint Seiya - $1 [DVD].mkv/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
24 $newname =~ s/^HajimeNoIppo.*Round(\d+)-.*\(anime-mx\)/[Anime-MX] Fighting Spirit - $1 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
25 $newname =~ s/^(\[ACX\])(Final Fantasy Unlimited) - (\d+) .*\[ALI\] /$1 $2 - $3 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
26 $newname =~ s/^\[a-s\] inuyasha - (\d+-\d+) rs2 /[a-S] Inuyasha - $1 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
27 $newname =~ s/^(\[Kira-Fansub\]) Uchuu no (Stellvia) /$1 $2 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
28 $newname =~ s/^(\[RaX\])(Chobits) - (\d+`\d) .*\(x264 aac\) /$1 $2 - $3 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
29 $newname =~ s/ Maria( |†)Holic / Maria+Holic /i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
30 $newname =~ s/^Legend of Galactic Heroes - (\d+) \(([A-F0-9]{8})\) \[Central Anime\]/[Central Anime] Legend of Galactic Heroes - $1 [$2]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
31 $newname =~ s/\[Hnk\]/[HnK]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
32 $newname =~ s/^Inuyasha - (\d+|\d+-\d+)\[167\] - .*(\[DVD\]\[AHQ\])/Inuyasha - $1 $2/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
33 $newname =~ s/^Saint Seiya Hades OVA - (\d+) \[(AonE-SpA|SpA)\]/[$2] Saint Seiya Hades OVA - $1/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
34 $newname =~ s/\[\d+\] Saint Seiya Hades OVA - (\d+)/[SpA] Saint Seiya Hades OVA - $1/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
35 $newname =~ s/ Digimon Tamers - (\d)\./ Digimon Tamers - 0$1./;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
36 $newname =~ s/ Kore wa Zombie Desu ka / Kore wa Zombie desu ka /i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
37 $newname =~ s/ Infinite Stratos - IS - / Infinite Stratos - /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
38 $newname =~ s/\[Keroro\]\.(\d+)\.\[Xvid\.mp3\]\./[Keroro] Keroro Gunsou - $1 /i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
39 $newname =~ s/\[Keroro\] \.(\d+)\. \[\.mp3\] \. /[Keroro] Keroro Gunsou - $1 /i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
40 $newname =~ s/Shadow\.Star\.Narutaru\.(\d+)\.\(Dual\.Audio\)\.XVID\.\[AM\]/[AM] Narutaru - $1 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
41 $newname =~ s/Outlaw Star Remastered E(\d+) .*'/ Outlaw Star - $1 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
42 $newname =~ s/Ground Defense Force Mao-chan (\d+)\[h\.264-AAC\]\[SSP-Corp\]/[SSP-Corp] Mao-chan - $1 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
43 $newname =~ s/Koi Kaze (\d+) \[NAG&anime fin\]/[NAG anime-fin] Koi Kaze - $1 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
44 $newname =~ s/ Toradora - / Toradora! - /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
45 $newname =~ s/ Dragon Crisis / Dragon Crisis! /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
46 $newname =~ s/ Mao Chan / Mao-chan /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
47 $newname =~ s/^Arigatou\.Bleach\.(\d+)\.\[h264\.AAC\]/Bleach - $1 [Arigatou]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
48 $newname =~ s/^Arigatou\.Bleach\.(\d+)\.\[x264\.AAC\]/Bleach - $1 [Arigatou]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
49 $newname =~ s/^Arigatou\.Bleach\.(\d+)\. \[\.AAC\]/Bleach - $1 [Arigatou]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
50 $newname =~ s/^Arigatou\.Bleach\.(\d+)v2\. \[\.AAC\]/Bleach - $1 [Arigatou][v2]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
51 $newname =~ s/ Ep(\d+)v3 \[R2 Video\]/ - $1 [v3]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
52 $newname =~ s/ Brighter Than The Dawning Blue - Crescent Love Ep(\d+) Subbed / Brigher Than The Dawning Blue - Crescent Love - $1 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
53 $newname =~ s/ Brighter Than The Dawning Blue - Crescent Love - (\d+) Subbed / Brigher Than The Dawning Blue - Crescent Love - $1 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
54 $newname =~ s/ Character Monologue 0/ Character Monologue /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
55 $newname =~ s/Ookami-san\.to\.Shichinin\.no\.Nakama-tachi\.EP(\d+)\(BD\.1080p\.AAC\)/Ookami-san - $1 [1080p BD]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
56 $newname =~ s/Ore.?tachi ni tsubasa wa nai /Oretachi ni Tsubasa wa nai /i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
57 $newname =~ s/\[anime-rg . ray=out\]/[anime-rg ray=out]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
58 $newname =~ s/^Arigatou\.Soul\.Eater\.Ep(\d+)\. \[x264\.AAC\]/[Arigatou] Soul Eater - $1 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
59 $newname =~ s/^\[Doremi\]\.HeartCatch\.PreCure!\.(\d+)\.\[1280x720\]\./[Doremi] HeartCatch PreCure! - $1 [720p]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
60 $newname =~ s/^\[Doremi-CureCom\]\.Suite\.PreCure!\.(\d+)\.\[1280x720\]\./[Doremi-CureCom] Suite PreCure! - $1 [720p]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
61 $newname =~ s/^\[Doremi\]\.Motto\.Ojamajo\.Doremi\.(\d+)\./[Doremi] Motto Ojamajo Doremi - $1 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
62 $newname =~ s/^\[HorribleSubs\] Lilpri /[HorribleSubs] Hime Chen! Otogi Chikku Idol Lilpri - /i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
63 $newname =~ s/^\[Jumonji-Giri\] \[AnY\]/[Jumonji-Giri]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
64 $newname =~ s/\[(BWS|PM)\]Pocket Monsters Best Wishes (\d+) .+\[H264 /[$1] Pokemon Best Wishes - $2 [/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
65 $newname =~ s/ Ookiku Furikabutte - The Summer Tournament Chapter / Ookiku Furikabutte S2 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
66 $newname =~ s/Les Miserables Shoujo Cosette /Les Miserables /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
67 $newname =~ s/\[Elysium\]Baka\.to\.Test\.to\.Shoukanjuu\.(EP)?/[Elysium] Baka to Test to Shokanju/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
68 $newname =~ s/\[Elysium\] Baka to Test to Shokanju/[Elysium] Baka to Test to Shokanju /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
69 $newname =~ s/\(BD\.1080p\.FLAC\)/[1080p BD]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
70 $newname =~ s/Saizen & SD/Saizen-SD/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
71 $newname =~ s/Bleach - (\d{2}) /Bleach - 0$1 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
72 $newname =~ s/Omamori Himari - ED \(Clean\) - 0(\d) / Omamori Himari - Ending $1 (Clean) /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
73 $newname =~ s/Omamori Himari - Opening \(Clean\) - (\d{2}) / Omamori Himari - Opening $1 (Clean) /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
74 $newname =~ s/\(B-A\)Great Teacher Onizuka - Lesson /[B-A] Great Teacher Onizuka - /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
75 $newname =~ s/Xam'd Lost Memories - (\d+) .* \[1080p,BluRay,,DTS\] - THORA\.mkv/[THORA] Xam'd Lost Memories - $1 [1080p BD].mkv/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
76 $newname =~ s/\(G P\) Escaflowne \(Remastered\)/[G_P] Escaflowne/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
77 $newname =~ s/SD&Taka/SD-Taka/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
78 $newname =~ s/Seikai no Senki/Banner of the Stars/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
79 $newname =~ s/Onii-chan no Koto \.\.\. /Onii-chan no Koto Nanka Zenzen Suki Janain Dakara ne /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
80 $newname =~ s/Onii-chan no Koto Nanka Zenzen Suki Janain Dakara ne /Onii-chan no Koto Nanka Zenzen Suki Janain Dakara ne!! /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
81 $newname =~ s/^Strawberry 100% - (\d+\.?\d*) \[ReDone-MDC\]/[ReDone-MDC] Strawberry 100% - $1 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
82 $newname =~ s/^Strawberry 100% - OVA 0(\d+\.?\d*) \[ReDone-MDC\]/[ReDone-MDC] Strawberry 100% OVA - $1 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
83 $newname =~ s/Dragonball Kai/Dragon Ball Kai/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
84 $newname =~ s/Natsu no Arashi - Akinai-chuu/Summer Storm! - Open for Business/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
85 $newname =~ s/Natsu no Arashi/Summer Storm!/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
86 $newname =~ s/Naruto (\d+-\d+) /Naruto - $1 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
87 $newname =~ s/Lupin III Series 1 - (\d+) - .+ \[neo1024\]/[neo1024] Lupin III - $1 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
88 $newname =~ s/Mitsudomoe Picture Drama - 0/Mitsudomoe Picture Drama - /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
89 $newname =~ s/Sora no Woto - ([^ ]+) \[BD 1080p\]\[AtsA\]/[AtsA] Sora no Woto - $1 [1080p BD]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
90 $newname =~ s/Battle\.Programmer\.Shirase\./Battle Programmer Shirase /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
91 $newname =~ s/Battle Programmer Shirase - 0/Battle Programmer Shirase - /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
92 $newname =~ s/ Kuragehime / Princess Jellyfish /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
93 $newname =~ s/^\[OZC\]Code Geass Lelouch of the Rebellion R2 E(\d+) .*/[OZC] Code Geass R2 - $1.mkv/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
94 $newname =~ s/ Panty and Stocking with Garterbelt / Panty & Stocking with Garterbelt /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
95 $newname =~ s/ Spice and Wolf S2 / Spice and Wolf II /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
96 $newname =~ s/\[A-E & Saizen\]/[A-E Saizen]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
97 $newname =~ s/\[Flomp\]\[SD\]/[Flomp]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
98 $newname =~ s/\[Jumonji-Giri\]\[Ishin\]/[Jumonji-Giri]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
99 $newname =~ s/\[Jumonji-Giri\]\[F-B&A-E\]/[Jumonji-Giri]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
100 $newname =~ s/\[Jumonji-Giri\] \[Lunar\]/[Jumonji-Giri]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
101 $newname =~ s/\[A-Kraze & Diffusion\]/[A-Kraze Diffusion]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
102 $newname =~ s/ The Story Of Saiunkoku / Saiunkoku Monogatari /i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
103 $newname =~ s/Code Geass Lelouch of the Rebellion Episode (\d+) .*(\.mkv)$/ Code Geass - $1$2/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
104 $newname =~ s/ To LOVE-Ru / To Love-Ru /i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
105 $newname =~ s/ Inuyasha Kanketsuhen / Inuyasha Kanketsu-hen /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
106 $newname =~ s/ AIR / Air /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
107 $newname =~ s/ Sister Princess Re Pure / Sister Princess Repure /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
108 $newname =~ s/C:\\Users\\Gad\\Desktop\\yankee-megane\\Release\\//;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
109 $newname =~ s/\(END\)/[End]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
110 $newname =~ s/\(BD 1280x720 h264 JP.EN AAC\)/[720p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
111 $newname =~ s/\[Final\]//i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
112 $newname =~ s/DB&L-E/DB L-E/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
113 $newname =~ s/IY-F&Oki/IY-F Oki/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
114 $newname =~ s/L-E&AonE/AonE L-E/;
4
94ee419ad047 Added bin-ec - a collection of scripts.
Edho Prima Arief <me@myconan.net>
parents:
diff changeset
115 $newname =~ s/^(Detective Conan - [[:digit:]]+-?[[:digit:]]*) (\[DCTP[^]]*\])(.+)$/$2 $1 $3/;
36
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
116 $newname =~ s/^(Detective Conan - [[:digit:]]+-?[[:digit:]]*) (\[AZFS[^]]*\])(.+)$/$2 $1 $3/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
117 $newname =~ s/^\[Derp\] Legend of the Legendary Heroes /[Derp] The Legend of the Legendary Heroes /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
118 $newname =~ s/ Sengoku BASARA Two / Sengoku Basara Two /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
119 $newname =~ s/ Asobi ni Ikuyo! / Asobi ni Iku Yo! /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
120 $newname =~ s/ Shinrei Tantei Yakumo / Psychic Detective Yakumo /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
121 $newname =~ s/ Ikkitousen Xtreme Xecutor OVA - 0/ Ikkitousen Xtreme Xecutor OVA - /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
122 $newname =~ s/ Megane na Kanojo OVA - 0/ Megane na Kanojo OVA - /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
123 $newname =~ s/\.Strange\.Dawn\.(\d+)\./ Strange Dawn - $1 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
124 $newname =~ s/ (Tegami Bachi|Letter Bee) REVERSE / Letter Bee Reverse /i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
125 $newname =~ s/ Sora No Otoshimono / Sora no Otoshimono /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
126 $newname =~ s/ Kidou Tenshi Angelic Layer (ep)?/ Angelic Layer /i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
127 $newname =~ s/ Sora No Otoshimono - Forte / Sora no Otoshimono Forte /i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
128 $newname =~ s/ Shinryaku! Ika Musume / Squid Girl /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
129 #$newname =~ s/ Squid Girl / Shinryaku! Ika Musume /;
11
8a0391d8e8d0 More ren evilry
Edho Prima Arief <me@myconan.net>
parents: 4
diff changeset
130 $newname =~ s/ Seikimatsu Occult Gakuin / Occult Academy /;
36
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
131 $newname =~ s/ Arakawa Under the Bridge ×2 / Arakawa Under the Bridge x2 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
132 $newname =~ s/ K-ON!! S2 / K-ON!! /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
133 $newname =~ s/ Ookami-san To Shichinin No Nakama-tachi / Ookami-san /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
134 $newname =~ s/ K-On!! / K-ON!! /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
135 $newname =~ s/ Ore No Imouto / Ore no Imouto /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
136 $newname =~ s/ A Certain Magical Index II / Toaru Majutsu no Index II /i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
137 $newname =~ s/ TV Broadcast \[720p/ [LQ 720p/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
138 $newname =~ s/ ED(\d)/ - Ending $1 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
139 $newname =~ s/ OP(\d)/ - Opening $1 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
140 $newname =~ s/ ED / - Ending /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
141 $newname =~ s/ NCED / - Ending (Clean) /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
142 $newname =~ s/ NCOP / - Opening (Clean)/;
11
8a0391d8e8d0 More ren evilry
Edho Prima Arief <me@myconan.net>
parents: 4
diff changeset
143 $newname =~ s/ OP / - Opening /;
36
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
144 $newname =~ s/ - - / - /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
145 $newname =~ s/ Ep / /ig;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
146 #GENERAL RULES
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
147 $newname =~ s/\.DVD/[DVD]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
148 $newname =~ s/ ~(.+)~ / - $1 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
149 $newname =~ s/v2 \(BD-1080p\) / [v2 1080p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
150 $newname =~ s/v2 \(BD H264 1280x960 24fps AAC\) / [v2 960p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
151 $newname =~ s/BD 1280x720 FLAC\]/ 720p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
152 $newname =~ s/\[HD\]\.mp4/.mp4/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
153 $newname =~ s/\[\.?AC3\]//i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
154 $newname =~ s/\[720p H264 AAC5\.1\]/[720p]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
155 $newname =~ s/\[BD 720p\]/[720p BD]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
156 $newname =~ s/ \(BD H264 1280x960 24fps AAC\) / [960p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
157 $newname =~ s/ \(h\.264\) //i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
158 $newname =~ s/\(xvid-mp3\)//i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
159 $newname =~ s/\(BD 1920x1080 *\)/[1080p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
160 $newname =~ s/v3 \(BD-1080p\) / [v3 1080p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
161 $newname =~ s/v0 \[720p\]/ [v0 720p]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
162 $newname =~ s/v0 \[/ [v0 /i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
163 $newname =~ s/\[1080p - Bluray\]/[1080p BD]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
164 $newname =~ s/\[Bluray - 1080p\]/[1080p BD]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
165 $newname =~ s/\[BD 1080p AAC\]/[1080p BD]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
166 $newname =~ s/ \(BD-1080p\) / [1080p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
167 $newname =~ s/ \(720p, BD\) / [720p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
168 $newname =~ s/ \(BD 1280x960 24fps 5\.1ch\) / [960p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
169 $newname =~ s/ \(Bluray, 720p, AAC\) / [720p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
170 $newname =~ s/ \(720p,BluRay\) / [720p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
171 $newname =~ s/ \(BD, 720p, FLAC\) / [720p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
172 $newname =~ s/\[END\]/[End]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
173 $newname =~ s/\[BD\]\[720p FLAC\]/[720p BD]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
174 $newname =~ s/\[BD\]\[720p\]/[720p BD]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
175 $newname =~ s/\[BD\]\[1080p\]/[1080p BD]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
176 $newname =~ s/\[h264-480p AAC\]//;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
177 $newname =~ s/\[h.264-480p\]//i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
178 $newname =~ s/ v3 \[720p\]/[v3 720p]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
179 $newname =~ s/1280x720 H264 OGG/720p/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
180 $newname =~ s/ \[BD 1080p FLAC\]/ [1080p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
181 $newname =~ s/ \[720p BD FLAC\]/ [720p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
182 $newname =~ s/ \[720p Blu-ray AAC\]/ [720p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
183 $newname =~ s/ \[BD\]\[h264-1080p FLAC\]/ [1080p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
184 $newname =~ s/ \(1920x1080\) \[BD\]/ [1080p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
185 $newname =~ s/ \(960x720 Blu-Ray FLAC\) / [720p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
186 $newname =~ s/ \(1920x1080 Blu-Ray FLAC\) / [1080p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
187 $newname =~ s/ \(1280x720 Blu-Ray FLAC\) / [720p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
188 $newname =~ s/ \(1280x720 h264 BD FLAC\) / [720p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
189 $newname =~ s/ \(704x480 DVD AAC\) / [DVD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
190 $newname =~ s/ \(960x720\) \[BD\]/ [720p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
191 $newname =~ s/\(704x396\)//;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
192 $newname =~ s/\(1280x720\)/ [720p]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
193 $newname =~ s/\(1920x1080\)/ [1080p]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
194 $newname =~ s/\(720x480 DVD AC3\)/ [DVD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
195 $newname =~ s/\(1024x576\)/ [576p]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
196 $newname =~ s/\(1280x720 h264\)/ [720p]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
197 $newname =~ s/\(1280x720 ?(h264|x264)?( aac)?\)/ [720p]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
198 $newname =~ s/\(720p\)/[720p]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
199 $newname =~ s/\(1080p\)/[1080p]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
200 $newname =~ s/\(1080p,BD\)/[1080p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
201 $newname =~ s/\(BD,1080p\)/[1080p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
202 $newname =~ s/\((BD 720p)\)/ [720p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
203 $newname =~ s/\(DVD\)/ [DVD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
204 $newname =~ s/\[h264-480p\]//i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
205 $newname =~ s/\[H264\]//i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
206 $newname =~ s/\[DVD\]\[v2\]/[v2 DVD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
207 $newname =~ s/xvid//i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
208 $newname =~ s/\[AC3\]//i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
209 $newname =~ s/\[H264&MP3\]//i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
210 $newname =~ s/\[H264-AAC\]//i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
211 $newname =~ s/\+AAC//i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
212 $newname =~ s/\[720x480 H264-Vorbis\]//i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
213 $newname =~ s/\[BD\]\[1280x720 H264-Flac\]/[720p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
214 $newname =~ s/\[h264 Vorbis\]//i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
215 $newname =~ s/\[640x480 h\.264 AAC\]//i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
216 $newname =~ s/\[720x480 AR h\.264 AAC\]//i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
217 $newname =~ s/\[DVD H264 640x476\]/[DVD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
218 $newname =~ s/\[720p\]/[720p]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
219 $newname =~ s/\[720p\]\[BD\]/[720p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
220 $newname =~ s/\[H264 1280x720\]/[720p]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
221 $newname =~ s/\[H264 1280x720 OGG\]/[720p]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
222 $newname =~ s/\[1280x720\]/[720p]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
223 $newname =~ s/\[1280x720 BD\]/[720p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
224 $newname =~ s/\[h264-720p\]/[720p]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
225 $newname =~ s/\[h264-1080p FLAC\]/[1080p]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
226 $newname =~ s/\[BD\]\[h264-1080p AC3\]/[1080p BD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
227 $newname =~ s/\[-/[/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
228 $newname =~ s/ \(1280x720 x264 AAC\)/ [720p]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
229 $newname =~ s/\[720p\]\[v2\]/[v2 720p]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
230 $newname =~ s/\[480p\]//i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
231 $newname =~ s/\[v2\]\[720p\]/[v2 720p]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
232 $newname =~ s/\[H264 - AAC\]//i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
233 $newname =~ s/\[H264 1280x720 AAC\] /[720p]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
234 $newname =~ s/\[720p\]\[End\]/[End 720p]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
235 $newname =~ s/ R2 DVD\(H264\.AC3\)/ [DVD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
236 $newname =~ s/ - Ep / - /i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
237 $newname =~ s/(h|x)\.?264//i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
238 $newname =~ s/\[BD\]\[1080p-?\]/[1080p BD]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
239 $newname =~ s/AAC5\.1//;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
240 $newname =~ s/FLAC//;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
241 $newname =~ s/ aac//i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
242 $newname =~ s/ ac3//i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
243 $newname =~ s/\.DVD/ [DVD]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
244 $newname =~ s/ DVD / [DVD] /i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
245 $newname =~ s/\(DVD ?\)/ [DVD] /i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
246 $newname =~ s/ Ep(\d+) / - $1 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
247 $newname =~ s/ Ep(\d+)v2 / - $1 [v2]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
248 $newname =~ s/ (\d+) / - $1 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
249 $newname =~ s/ (\d+)v(2|3) / $1 [v${2}]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
250 $newname =~ s/\[720x480 AR FLAC\]//i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
251 $newname =~ s/\[DVD 640x480\]/[DVD]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
252 $newname =~ s/ Episode (- )+(\d+) / - $2 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
253 #DANGEROUS CLEANUPS
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
254 $newname =~ s/ \[v(2|3)\]\[(.+)\]\[([0-9A-Fa-f]{8})\]/ [v$1 $2][$3]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
255 $newname =~ s/\]/] /g;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
256 $newname =~ s/\[/ [/g;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
257 $newname =~ s/\] +\[/][/g;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
258 $newname =~ s/\[ +/[/g;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
259 $newname =~ s/ +\]/]/g;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
260 $newname =~ s/( -)+ / - /g;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
261 $newname =~ s/(\[|\()([0-9a-fA-F]{8})(\]|\))/[\U$2]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
262 $newname =~ s/ +(\.\w{3})$/$1/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
263 $newname =~ s/\[\]//g;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
264 $newname =~ s/\(\)//g;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
265 #EXCEPTIONS
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
266 $newname =~ s/^\[DB&L-E\]/[DB L-E]/;
11
8a0391d8e8d0 More ren evilry
Edho Prima Arief <me@myconan.net>
parents: 4
diff changeset
267 $newname =~ s/ VS Knight Lamune & - 40 fire / VS Knight Lamune & 40 fire /;
36
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
268 $newname =~ s/ RAINBOW / Rainbow /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
269 $newname =~ s/ Golgo - 13 / Golgo 13 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
270 $newname =~ s/ Strike Witches - 2 / Strike Witches 2 - /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
271 $newname =~ s/ 07-GHOST / 07-Ghost /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
272 $newname =~ s/ K-ON!! B-Side Theater - Uraon!! - / K-ON!! B-Side Theater - Uraon!! /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
273 $newname =~ s/ Captain Tsubasa Road to - 2002 / Captain Tsubasa Road to 2002 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
274 $newname =~ s/ SP0/ - Special /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
275 $newname =~ s/ Special - / - Special /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
276 $newname =~ s/ Opening - / Opening /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
277 $newname =~ s/ Ending - / Ending /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
278 $newname =~ s/ Hidamari Sketch Hoshimittsu - Special / Hidamari Sketch Hoshimittsu Special - /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
279 $newname =~ s/ Spice and Wolf S2 - BD Menu - 0/ Spice and Wolf S2 - BD Menu /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
280 $newname =~ s/ Canvas - 2 - / Canvas 2 - /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
281 $newname =~ s/ Mitsudomoe - 2 - / Mitsudomoe 2 - /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
282 $newname =~ s/ Eyeshield - 21 - / Eyeshield 21 - /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
283 $newname =~ s/ Eyeshield 21 - (\d{2}) / Eyeshield 21 - 0$1 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
284 $newname =~ s/ Eyeshield 21 - (\d{2})-(\d{2}) / Eyeshield 21 - 0$1-0$2 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
285 $newname =~ s/ - 2010 Young Animator / 2010 Young Animator /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
286 $newname =~ s/\[G P\]/[G_P]/i;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
287 #SAFE CLEANUPS
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
288 $newname =~ s/ +/ /g;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
289 $newname =~ s/^ +//;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
290 $newname =~ s/(- )+/- /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
291 $newname =~ s/^\[N - F\]/[N-F]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
292 $newname =~ s/^\[K-F & AKUPX\]/[K-F AKUPX]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
293 $newname =~ s/^\[([\s\w\- ]+)\] (Kyou Kara Maou|Bleach|Naruto|One Piece|Detective Conan) - (Opening \d+|Special \d+|\d+|\d+-\d+) /$2 - $3 [$1]/;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
294 $newname =~ s/^Naruto - (\d{2}) /Naruto - 0$1 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
295 $newname =~ s/^Naruto - (\d{2})-(\d{2}) /Naruto - 0$1-0$2 /;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
296 print(qq($_: $newname already exists, skipping\n)) and next() if -e $newname and $_ ne $newname;
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
297 if ($_ eq $newname) {
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
298 print("$_: no need to rename, skipping\n");
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
299 } else {
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
300 if($skip==1) { print("Result: $_ --> $newname\n"); }
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
301 else {
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
302 if(rename($_, $newname)) { print("$_ -> $newname\n"); }
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
303 else { print("$_: rename failed\n"); }
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
304 }
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
305 }
3bcef95c376c Revamped ren!
Edho Prima Arief <me@myconan.net>
parents: 19
diff changeset
306 next();
4
94ee419ad047 Added bin-ec - a collection of scripts.
Edho Prima Arief <me@myconan.net>
parents:
diff changeset
307 }
94ee419ad047 Added bin-ec - a collection of scripts.
Edho Prima Arief <me@myconan.net>
parents:
diff changeset
308
94ee419ad047 Added bin-ec - a collection of scripts.
Edho Prima Arief <me@myconan.net>
parents:
diff changeset
309 exit(0);