Prevent folder opening on completion?

Support for macOS users and the Mac App Store package
Post Reply
Posts: 1
Joined: 04 May 2021, 05:27

Prevent folder opening on completion?

Post by aronmc94 »

Hi all,

I'm brand new to this app and tired now so please forgive me if I'm being slow, but is there a way to prevent the Finder window opening with target directory on completion? I'm running the amc script via shell in Automator folder action script monitoring my Downloads folder. I'd like to run this completely automated and invisible (with the exception of Gmail log sent) unless theres any errors. Obviously the console only shows the log if there are errors, but on completion of the task the Finder window pops up to display the new files in their new location. Is there a way to disable this? I've done hours of searching and Googling but I can't seem to find anything.. hidden in plain sight perhaps? This didn't happen when I was evaluating of course because there were no output files to display in Finder.

Ideally I'd also like a way to delete the leftover empty source directory, but I understand why Filebot doesn't 'delete' anything. I'm using the 'clean' command, but it still leaves the empty parent folder remaining.

Any help is very much appreciated! Thanks.

User avatar
The Source
Posts: 19693
Joined: 16 Nov 2011, 08:59
Location: Taipei

Re: Prevent folder opening on completion?

Post by rednoah »

You can remove these behaviors by removing the corresponding code.

e.g. This piece of code is responsible for revealing newly processed files in Finder:

Code: Select all

-exec open -R {f} +
e.g. This piece of code is responsible for opening the log file on error:

Code: Select all

# Display log file on error
if [ $? -ne 0 ]; then
	open "$CONFIG_LOG"

You can make a dedicated cleaner script call with custom options at the end of your shell script if you need more control over prune / clean behaviour:


Code: Select all

filebot -script fn:cleaner "[email protected]" --log-file "$CONFIG_LOG" --def root=y
:idea: Please read the FAQ and How to Request Help.
Post Reply