View Single Post
Old 09-03-2010, 06:39 PM   #47
lilman
Addict
lilman has learned how to read e-bookslilman has learned how to read e-bookslilman has learned how to read e-bookslilman has learned how to read e-bookslilman has learned how to read e-bookslilman has learned how to read e-bookslilman has learned how to read e-bookslilman has learned how to read e-books
 
lilman's Avatar
 
Posts: 326
Karma: 960
Join Date: Jul 2009
Location: Florida, US
Device: Kindle DX, iPad
I just wrote a Canti batch file creator. What it does is you run it like:
Code:
java -jar BatchManga.jar [path to manga collection] [path to Canti manga processed output folder]
For example:
Code:
java -jar BatchManga.jar /home/andrew/Manga/ /home/andrew/Manga_IPAD/
It will read all the folders in your manga collection and create a batch file for Canti to process your entire collection. For example, let's say /home/andrew/Manga/ has the following folders:
CandidateForGoddess/
MahouSenseiNegima!/
SchoolRumble/
Since I'm running this on Linux in this case, it will create a shell script called process_all_manga.sh with the following contents:
Code:
#!/bin/sh
java -jar Canti.jar -parent_folder '/home/andrew/Manga/CandidateForGoddess/' -title 'Candidate for Goddess' -manga_prefix "Vol." -output_folder '/home/andrew/Manga_IPAD/Candidate_for_Goddess/'
java -jar Canti.jar -parent_folder '/home/andrew/Manga/MahouSenseiNegima!/' -title 'Mahou Sensei Negima!' -manga_prefix "Ch." -output_folder '/home/andrew/Manga_IPAD/Mahou_Sensei_Negima!/'
java -jar Canti.jar -parent_folder '/home/andrew/Manga/SchoolRumble/' -title 'School Rumble' -manga_prefix "Ch." -output_folder '/home/andrew/Manga_IPAD/School_Rumble/'
Some important things to note from this example:
  • Even though the words in the source manga folder names are all bunched together (example: SchoolRumble) the program knows to expand this out in the title and output folder to "School Rumble" and "School_Rumble" respectively. In other words, the program does a pretty good job of guessing the correct spaces in a title if you don't have them already properly spaced.
  • Source folder "CandidateForGoddess" was interpreted as title "Candidate for Goddess". The program has a built-in list of words that should not be capitalized in a title (in this case, "For"), but I could also make an external file so that the user could set their own list of words that should not be capitalized in titles.
  • Of the three example folders given, only folder "CandidateForGoddess" was given manga_prefix "Vol.", while the other two folders were given manga_prefix "Ch.". The default manga_prefix for this program is "Ch.", but because the "CandidateForGoddess" folder contained a binding file in it, the program gave it the "Vol." manga_prefix instead (since the output is going to use binding).
Thus, you can process your entire manga collection just by executing the batch script. Of course, you'll need to edit the output script a little for small spelling changes (it isn't perfect at determining the proper title), but for the most part this is a huge time save over manually writing out Canti command lines.

The program is currently at a point where I can use it so I'm not planning on spending any more time on it, but if there is interest in it I will continue its development (including Windows support, which should already work but hasn't been tested). So reply if you would like this program.
lilman is offline   Reply With Quote