I'd like to add the run command on utorrent but I only want it to work with certain labels.
Is there a way to tell it to run only on certain labels, or to ignore certain labels other than putting "ignore" infront of every other label or messing with the script?
AMC with utorrent only on selected tags
Re: AMC with utorrent only on selected tags
The exec command is called for each processed file, regardless of label, but if label is ignore then no files are processed and nothing is executed.
What you want is not supported, but since you do have full control over the command template...
The escaping might be a bit tricky, but you can completely change what commands are executed depending on the label, file, etc
What you want is not supported, but since you do have full control over the command template...
Code: Select all
--def "exec=do {label =~ /dummy/ ? 'nothing' : 'something'} '{file}'"
-
- Posts: 23
- Joined: 05 Mar 2015, 21:59
Re: AMC with utorrent only on selected tags
Hi rednoah,
I am looking to implement a code similar to that mentioned by psxlover above. I am having a little difficulty applying your suggestion though. Assuming I am using the default AMC code:
Is the default AMC code included within your advised code, for example:
Or is the advised code included within the default AMC code, for example:
Can you please also assist by specifying what the variables are in your above code? I assume:
dummy = label
nothing = action if label is matched (leave blank if you want nothing to happen)
something = action if label is not matched (leave blank if you want nothing to happen)
Thanks for your help as always.
I am looking to implement a code similar to that mentioned by psxlover above. I am having a little difficulty applying your suggestion though. Assuming I am using the default AMC code:
Code: Select all
filebot -script fn:amc --output "X:/path/to/media" --log-file amc.log --action copy --conflict override -non-strict --def music=y subtitles=en artwork=y "ut_label=%L" "ut_state=%S" "ut_title=%N" "ut_kind=%K" "ut_file=%F" "ut_dir=%D"
Code: Select all
--def "exec=do {label =~ /dummy/ ? 'nothing' : ' '{file}'" filebot -script fn:amc --output "X:/path/to/media" --log-file amc.log --action copy --conflict override -non-strict --def music=y subtitles=en artwork=y "ut_label=%L" "ut_state=%S" "ut_title=%N" "ut_kind=%K" "ut_file=%F" "ut_dir=%D"'}
Code: Select all
filebot -script fn:amc --output "X:/path/to/media" --log-file amc.log --action copy --conflict override -non-strict --def music=y subtitles=en artwork=y "ut_label=%L" "ut_state=%S" "ut_title=%N" "ut_kind=%K" "ut_file=%F" "ut_dir=%D"--def "exec=do {label =~ /dummy/ ? 'nothing' : 'something'} '{file}'"
dummy = label
nothing = action if label is matched (leave blank if you want nothing to happen)
something = action if label is not matched (leave blank if you want nothing to happen)
Thanks for your help as always.
Re: AMC with utorrent only on selected tags
1)
exec is a script option, so it's filebot -script ... --def exec=command syntax.
2)
{label} is whatever you pass in via --def ut_label=value.
3)
Do you understand how the format works? The --def exec option works exactly the same way except that you're building a command which is subsequently executed.
In the example above a fictitious command called "do" would be called for each file, and what exact parameters are passed when executing "do" should be obvious.
exec is a script option, so it's filebot -script ... --def exec=command syntax.
2)
{label} is whatever you pass in via --def ut_label=value.
3)
Do you understand how the format works? The --def exec option works exactly the same way except that you're building a command which is subsequently executed.
In the example above a fictitious command called "do" would be called for each file, and what exact parameters are passed when executing "do" should be obvious.