[Script] Custom Rules for Featurettes, Extras, etc

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

[Script] Custom Rules for Featurettes, Extras, etc

Post by rednoah »

This post-processing script will process companion files based on custom code:

Groovy: Select all

{ source, target ->
	source.dir.listFiles{ f ->
		// select Special Features and move them to a Featurettes subfolder (e.g. Jaws-SF_04_DS_Outtakes_t03.mkv)
		if (f.video && f.name.findWordMatch(/SF/)) {
			// move, copy, symlink, hardlink, etc
			action(f, target.dir / 'Featurettes' / f.name)
		}
	}
}


:idea: This sample code ☝️ is work in progress. Please share sample file names for your featurettes, extras, trailers, etc and how you would like to organise them, so that we can add more rules to the sample code above and make things work better out-of-the-box for everyone.
:idea: Please read the FAQ and How to Request Help.
Post Reply