Any Mass Renaming

Running FileBot from the console, Groovy / FileBot scripting, shell scripts, etc
Post Reply
User avatar
The Source
Posts: 18546
Joined: 16 Nov 2011, 08:59
Location: Taipei

Any Mass Renaming

Post by rednoah » 08 Feb 2012, 07:58

You can use scripting to do any kind of mass-renaming. Especially useful if you wanna add mediainfo to the filename like in this example here:

1. List video files
2. Rename files according to the given naming scheme (in this case keep existing name/extension but insert resolution in between)
3. Print new file paths

Code: Select all

args.getFiles{ it.isVideo() }.each {
   println it.moveTo(new File(getMediaInfo(file:it, format:"{fn} [{resolution}].{ext}")))
(requires -trust-script for filesystem write access)
:idea: Please read the FAQ and How to Request Help.

Post Reply