Useful scripts for PS2SMB (Linux) –
03-08-2011,11:57 PM
I just threw these together, they are designed for use on a linux server running samba.
These are very hacky, and are not my best work, but they serve the purpose.
These will not work on windows without some porting.
Well, maybe under cygwin but UNTESTED!
Tested only under Fedora 14.
In the zip there is a tools folder, extract it to your PS2SMB so that the tools folder is in your PS2SMB like the CD and DVD folders.
nameset:
Use in CD or DVD folder to auto rename your ISOs to have the S###_###.## format required. Requires a program called "isoinfo" to look up the iso filesystem. If this returns nothing, all files are already renamed.
Use in the CD or DVD directory.
$ cd DVD
$ ../tools/nameset
would rename:
Shining Force EXA.iso
to:
SLUS_215.67.Shining Force EXA.iso
namecheck:
Checks to make sure your name is 32 characters or less, and will tell you how much you need to shorten it by. If this returns nothing, everything is fine.
This script is primitive and has no sanity checks, using a "." in your game name will break this one. (Example: SLUS_215.67.Shining.Force.EXA.iso would not process correctly and only see "Shining")
Use in the CD or DVD directory.
$ cd DVD
$ ../tools/namecheck
Might return something like:
'Fullmetal Alchemist 2 - Curse of the Crimson Elixir' too long (by 19 chars)!
date2press:
This is just a simple script that uses isoinfo to get the time/date that the ISO was originally pressed by the publisher. There are no checks to verify if this data has been tampered with or not. It will set the creation/access/last modified date to the date it finds in the ISO header.
Use in the CD or DVD directory.
$ cd DVD
$ ../tools/date2press
This just lists each file as it processes them. View the result by following up with:
$ ls -l
getcover:
Use AFTER nameset, reads S### id from filename and looks for corresponding png (or jpg) for cover art in OPL Gallery.
Use in the CD or DVD directory.
$ cd DVD
$ ../tools/getcover
Will report success or failure of each cover. If nothing appears, all files have a cover successfully downloaded.
geticon:
Use AFTER nameset, reads S### id from filename and looks for corresponding png for icon art in OPL Gallery.
Use in the CD or DVD directory.
$ cd DVD
$ ../tools/geticon
Will report success or failure of each cover. If nothing appears, all files have a icon successfully downloaded.
I also have getcover and geticon to automatically populate your ART folder but I would need JNABK's permission to release them as they scrape the server.
Just one remark, when OPL 0.9 goes out, don't forget to update "namecheck", as now game names for ISO (only) are limited to 64 chars.
Also, there is a script floating around in the forum to allow mounting a real CD/DVD PS2 game disc into your PC computer DVD drive, and link into the PS2SMB share, so it can be accessible by OPL (useful if you don't want to rip some game, and want to try it with OPL).
Just one remark, when OPL 0.9 goes out, don't forget to update "namecheck", as now game names for ISO (only) are limited to 64 chars.
Also, there is a script floating around in the forum to allow mounting a real CD/DVD PS2 game disc into your PC computer DVD drive, and link into the PS2SMB share, so it can be accessible by OPL (useful if you don't want to rip some game, and want to try it with OPL).
Interesting. I wonder if that could be a simple symlink /dev/dvd > thefile.iso or something more complicated. But I just threw these together to help me out and figured I'd share for anyone else.
You mention support for 64 chars, does the latest source support this? Because I have set up the ps2sdk and all th at and am running the latest dev-revision.