Automation Script Question/Clarification

While I’m not currently making use of Sonarr, I am rather fond of @Ice_Nine 's script for automating the handling or torrented files.

@Ice_Nine , the former topic is now closed and I had a question about how you’ve further edited the script now that qBittorrent (v3.3.4) has “proper” variables (%N, et al) to hand off to a script to be run post-completion.

Have you made any further changes to the script since your original psoting back in Feb 2015?

Thanks much for your script ideas and assistance!

./s4z

Hi s4z,

When I originally wrote the script, qBittorrent’s post processing script handling was very basic - so I coded the script with the only real info qBit could pass at the time effectively (the torrent name, which luckily corresponded to the directory name you’d find on the filesystem). That’s why the script requires the segregation of media types (TV, Movies, Music, etc), since you have to test them all to see if the torrent lives there, and subsequently post-process it.

While it’s nice that qBit now supports passing additional parameters, and i’m sure many people are grateful for it, I myself am a huge believer in the KISS principle.

The interesting thing is that I’m not currently on a consulting assignment right now, so I have a lot of free time on my hands - time I could use to possibly extend this script’s functionality. The only problem is, it is so good at what it does, I’m not sure I’d ever approach this particular problem from a different angle.

All that said, if you have any requests for improvement, I’m certainly not opposed to taking some time to write some more bash code, even if I find bash kind of boring :slight_smile:

-k

Thanks for the reply!

I agree with you. KISS. And I like the way you do the parsing of the file types, etc.

I haven’t quite gotten the script functioning as you described - which is why I pinged you (realizing that qBit had added features) - I’m currently pointing qbit to /usr/sbin/torrent-pp.sh per your instructions, however I’ve added the “%N” variable (which is what I believe is what corresponds to the the former $1 (TOR) - However I am not sure… I’ll play with it a little and see if I can get it to work. Maybe I’ll force some logging of the variables and see which best corresponds. No doubt it’s a simple change in the Variable being used.

I really don’t see the need to make it more complicated. You may want to edit the COMMENTS at the beginning of the script to assist users of the current version(s) of qBit. That’s all I can think of.

Thanks again.

./s4z

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.