Disable TV Shows in groovy Script as Running Sonarr to handle TV Shows

Any questions? Need some help?
Post Reply
yodaspowart
Posts: 16
Joined: 02 Jun 2017, 01:04

Disable TV Shows in groovy Script as Running Sonarr to handle TV Shows

Post by yodaspowart »

Hi

Is there a way to Turn TV Shows OFF in terms of not even checking?

The log file is still showing TVs error as i'm using an out-of date filebot that doesn't support the new TVDB API.

I am handling all my TV Shows now through Sonarr.
Have commented out the TV Shows part of the script, but logs still show Filebot checking Transmission for TV Shows based on the error you get from the TVDB API.

Code: Select all

#!/bin/bash

export LANG=en_US.UTF-8
export LANGUAGE=en_US.UTF-8
export LC_CTYPE="en_US.UTF-8"

TORRENT_PATH="$TR_TORRENT_DIR/$TR_TORRENT_NAME"
TORRENT_NAME="$TR_TORRENT_NAME"
TORRENT_LABEL="N/A"

# Subtitle language
SUBLANG=en, pt
SKIP_EXTRACT=n
MUSIC=n

# rclone for moving files to gdrive
RCLONE_DIR="plex"

filebot -script /opt/filebot/scripts/amc.groovy \
--output "$HOME/MergerFS" \
-non-strict --encoding utf8 --log all --log-file amc-transmission.log --action copy --conflict auto \
--def artwork=false ut_kind=multi "ut_dir=$TORRENT_PATH" "ut_title=$TORRENT_NAME" subtitles=$SUBLANG \
--def "movieFormat={fn =~ /2160p|4K|4k|UHD/ ? '$RCLONE_DIR/Films 4K' : fn =~ /3D|3d|HSBS|3dhsbs|H-SBS|3dhou|H-OU/ ? '$RCLONE_DIR/Films 3D' : fn =~ /1080p|720p/ ? '$RCLONE_DIR/Films HD' : vf =~ /576p/ ? '$RCLONE_DIR/Films SD/576p' : vf =~ /480p/ ? '$RCLONE_DIR/Films SD/480p' : vf =~ /360p/ ? '$RCLONE_DIR/Films SD/360p' : vf =~ /240p/ ? '$RCLONE_DIR/Films SD/240p' : '$RCLONE_DIR/Films SD/root'}/{n} ({y}) - {allOf{match}{s3d}{hd}{vc}{vf}{n.findMatch(group) ? null : '- '+group} join ' '}{' CD'+pi}{'.'+lang}" \
# --def "seriesFormat={fn =~ /2160p|4K|4k|UHD/ ? '$RCLONE_DIR/TV Shows 4K' : fn =~ /1080p/ ? '$RCLONE_DIR/TV Shows HD' : 'TV Shows'}/{n}/{n} - {episode.special ? 'S00E'+special.pad(2) : s00e00} - {t.replaceAll(/[\`´‘’ʻ]/, /'/).replaceAll(/[!?.]+$/).replacePart(', Part \$1')} - {allOf{match}{hd}{vc}{vf}{n.findMatch(group) ? null : '- '+group} join ' '}{'.'+lang}" \
--def music=n --def unsorted=y --def unsortedFormat="$HOME/Stuff/Unsorted/{fn =~ /2160p|4K|4k|UHD/ ? 'UHD-2160p/' : fn =~ /1080p/ ? 'HD-1080p' : fn =~ /720p/ ? 'HD-720p' : 'SD'}/{fn.before(/S\d{2}E\d{2}/).upperInitial().space(' ')} - {fn.match(/S\d{2}E\d{2}/).upper()} - {fn.after(/S\d{2}E\d{2}/).stripReleaseInfo().upperInitial().space(' ')} [{allOf{match}{s3d}{hd}{vc}{source}{vf}{('-')}{af}{ac}{channels}{n.findMatch(group) ? null : '- '+group} join ' '}].{ext}" \
extractFolder="$HOME/files/_extracted" music=$MUSIC skipExtract=$SKIP_EXTRACT &
Thanks a lot!
User avatar
rednoah
The Source
Posts: 22976
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Disable TV Shows in groovy Script as Running Sonarr to handle TV Shows

Post by rednoah »

You could use the --def ignore option, to preemptively exclude file paths that contain certain keywords.

e.g. exclude all files that include the word "Sonarr" anywhere in the file path:

Code: Select all

--def ignore=Sonarr

:idea: I'd also add --def ut_label=Movie to force Movie Mode for all the remaining files.


:idea: Please read How to Request Help.
:idea: Please read the FAQ and How to Request Help.
yodaspowart
Posts: 16
Joined: 02 Jun 2017, 01:04

Re: Disable TV Shows in groovy Script as Running Sonarr to handle TV Shows

Post by yodaspowart »

Brilliant thanks @rednoah, this is perfect.
Post Reply