Usage of mi.groovy file

Support for Windows users
Post Reply
jerome
Posts: 31
Joined: 25 Feb 2019, 02:21

Usage of mi.groovy file

Post by jerome »

This was posted by Rednoah in scripting, and I managed to figure out how to get it to work.

Shell: Select all

filebot -script fn:mi /path/to/media --output /path/to/media-index.tsv
My assumption is that this runs from the filebot website and not locally. I tried to get it to reference a revised mi.groovy file I created locally with additional parameters for file analysis, but with no luck.

Is it even possible to run a mi.groovy file located on my PC?

J
User avatar
rednoah
The Source
Posts: 23002
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Usage of mi.groovy file

Post by rednoah »

You can run your own scripts:

Shell: Select all

filebot -script "/path/to/mi.groovy" "/path/to/media" --output "/path/to/media-index.tsv"
Please read Scripts and Automation for details.
:idea: Please read the FAQ and How to Request Help.
jerome
Posts: 31
Joined: 25 Feb 2019, 02:21

Re: Usage of mi.groovy file

Post by jerome »

Does that apply to all the filebot scripts?
I was able to get the Artwork.groovy file to work off my local PC but not the Artwork.TMDB.groovy file.

This is the command I used

Code: Select all

filebot -script D:/Sabnzbd/Scripts/Filebot_Artwork/artwork.tmdb.groovy D:\Sabnzbd\Complete\[movies]
I received two types of error messages.
ERROR MESSAGE 1

Code: Select all

No Such File: D:\Sabnzbd\Scripts\Filebot_Artwork\lib\htpc.groovy
ERROR MESSAGE 2

Code: Select all

D:\Sabnzbd\Complete\[movies]\UHDMovie_C\Color Purple, The (1985) [UHD ? 2160p ? Drama ? PG-13] => The Color Purple (1985)
No signature of method: net.filebot.GroovyEngine.fetchMovieArtworkAndNfo() is applicable for argument types: (File, net.filebot.web.Movie, File, Boolean, Locale) values: [D:\Sabnzbd\Complete\[movies]\UHDMovie_C\Color Purple, The (1985) [UHD ? 2160p ? Drama ? PG-13], ...]
I then tried removing the "include('lib/htpc')" from the groovy file which removed ERROR message 1 but ERROR message 2 remains and no artwork is downloaded.

J
User avatar
rednoah
The Source
Posts: 23002
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Usage of mi.groovy file

Post by rednoah »

Works the same for all scripts. It's your script that you write yourself after all.

Shell: Select all

filebot -script "/path/to/script.groovy"

:!: Scripts may consist of more than one file of course. Script files can load other script files. If you use local scripts then dependencies are expected to be locally available as well. So if you want to modify the more complex existing scripts, then you will want to clone (i.e. git clone) or download (i.e. Download as ZIP) the entire repository:
https://github.com/filebot/scripts
:idea: Please read the FAQ and How to Request Help.
Post Reply