Various scripts for the FTAG project.
Perl JavaScript PHP
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
legacy
userscripts
.gitignore
README.md
config.ini.default
ftag_copyrights.json
ftag_gui.pl
ftag_move.pl
rename2new.pl
strip_ftag.pl
striputf8.pl
sunzipme.pl
thumbgen_v2.pl
tkview.pl

README.md

FTAG Scripts

[NOTE: All of these scripts weren't build with the intention of other people using them, so apologies if they don't work & the lack of documentation..]

Scripts in this repo were built to be used alongside the FTAG Shimmie Branch and eventually the FTAG Client.

Main Scripts

  • strip_ftag
     This assumes any given filenames are the EH filename format.```
    
  • striputf8
     This will rename all known UTF8 characters to decent equivilents (or remove them), convert bad URL characters to good ones, and various other filename validation things.```
    
  • sunzipme
     It will: Convert all PNG > JPG, rename everything to 0001..0002..0003 etc., remove certain files, and prepend the JSON of the same name to the ZIP comment.```
    
  • tkview
     It is intended to be used on the ftag:// URI.  
     (Small note: The script isn't as up to date as the rest of my scripts. So errors beware...)```
    
  • userscripts/ehquickdl_ftag.user.js
     This really does too many things to list.```
    
    

Extra Scripts

  • rename2new
    This is intended to make renaming files in the FTAG project easy. Requires setting up a URI for ftagrename://

Basic Run Procedure

Just to give some insight into how everything here comes together, this is a basic example of how I do things.

  1. Download batch from EH while using Quick DL FTAG (As to grab the JSON).
  2. Move said batch to convertDir.
  3. Run striputf8 (Without -rename) > Add any new UTF8 to script. Do this until no errors.
  4. Run striputf8 (With -rename).
  5. Run sunzipme. ConvertDir should now be empty & renameDir should now have all the ZIPs.
  6. Run strip_ftag (Without -rename/-force) > Add any new parodies to json_copyrights. Repeat until complete (Script may match non parodies, but just ignore, or add to blacklist).
  7. Run strip_ftag (With -force). This checks for any other possible errors.
  8. Run strip_ftag (With -force -rename). This should rename everything in the folder to their new filenames, and move them to finalDir.
  9. Manually move everything from finalDir to zipDir. Append artist to end of filename if filename already exists.
  10. Run thumbgen_v2. Thumbs + CSV is now generated.
  11. Run bulk_add_csv (shimmie ext) against the CSV. This should import stuff into shimmie FTAG.
  12. Repeat 10 & 11 until thumbgen_v2 returns nothing. In cases where something returns but won't import, check for same MD5 images (sometimes different chapter sets).
  13. All done!

FAQ/Random INFO

Few things I think I should mention here.

  • ftag_copyrights isn't consistant on romanized/non-romanized/translated names. Most of it's personal choice, or shortform names that need to be chosen due to the 255char limit. I'll maybe fix this at a later date, but at the moment it works :\