2009-07-19, 15:01
Hey folks. Since this project was inspired by XBMC and these forums I thought I'd post about it here. My goal is to have a 100% automated TV show torrenting solution, with TED at the front, and XBMC at the end. I started developing some command-line utilities that fill in the gaps left by the various programs I use. I think some you heavy automation guys on the Windows side may like the stuff I've got planned.
The only thing I have finished right now is a beta of what I'm calling uTorrent Automator. Its very simple and only has two modes / functions at present:
Add Mode is used to add a .torrent task to uTorrent and then immediately apply a specified label to that task. If you enable the right options in uTorrent, this means you can control what subdirectory of your "Downloads" folder the finished files will be used as the destination. I plan on also making it possible to set the queuing properties of the torrent, so you can set up leachy settings for your auto-TV shows while leaving your main uTorrent settings alone.
Removal Mode simply finds any torrents that are still in uTorrent but have a status of "Finished" and removes them. This is a process that the author of uTorrent refuses to make automatic, which is what originally inspired me to begin writing stuff. If you go moving files around while their associated torrent jobs are still present in uTorrent, sometimes annoying things happen. If you set your "Queueing" settings correctly, you can have uTorrent automatically stop tasks once they complete, making this tool "see" and remove them.
Usage:
will trigger Removal Mode
Example:
uTorrentAutomator.exe 192.168.1.1:5000 admin admin
Will add the specified torrent file with the specified label.
Example:
uTorrentAutomator.exe 192.168.1.1:5000 admin admin TV %1
Will work inside of a Windows Batch file and will add the torrent called with it / dragged & dropped onto the batch file.
These are intended for use in a larger batch-driven scheme. I need to either write or find a "Directory Watcher" program which will trigger the download handler chains whenever new downloads complete.
My eventual handler chain will work like this:
TED will download torrents to some directory, which will automatically fire a batch script which uses uTorrentAutomator to add it to uTorrent + the TV label. The show will download to FinishedDownloads\TV, which will have a second directory watcher on it. The second one will fire a TV show manager batch tool, which will fire my uTorrentAutomator (for clearing the finished tasks), then probably TheRenamer, followed by another command-line tool I plan on writing which will call the "UpdateLibrary" function on my various installs of XBMC around the house.
I've got some other plans and welcome any feedback from you fine forum people
I have zipped and uploaded the app here. Its only 17K because its a command console / batch program. I haven't implemented any real error handling yet, so it will crash if it encounters a scenario it doesn't like.
If you guys have any other command-line program needs, I would be happy to throw something together for you, like 'take this filename, apply this RegEx to it and then spit the output back to the console". I'm sure we'll come up with some stuff. I also have some plans for implementing some other download handlers, mainly for the "Movies" label / download destination. Mostly the same as TV shows just with a few tweaks.
EDIT
Forgot to make sure its clear, this was made with C# and you will need the .NET Framework 3.5 installed. If you don't have it, its a free one time install, download here:
http://www.microsoft.com/downloads/detai...laylang=en
The only thing I have finished right now is a beta of what I'm calling uTorrent Automator. Its very simple and only has two modes / functions at present:
Add Mode is used to add a .torrent task to uTorrent and then immediately apply a specified label to that task. If you enable the right options in uTorrent, this means you can control what subdirectory of your "Downloads" folder the finished files will be used as the destination. I plan on also making it possible to set the queuing properties of the torrent, so you can set up leachy settings for your auto-TV shows while leaving your main uTorrent settings alone.
Removal Mode simply finds any torrents that are still in uTorrent but have a status of "Finished" and removes them. This is a process that the author of uTorrent refuses to make automatic, which is what originally inspired me to begin writing stuff. If you go moving files around while their associated torrent jobs are still present in uTorrent, sometimes annoying things happen. If you set your "Queueing" settings correctly, you can have uTorrent automatically stop tasks once they complete, making this tool "see" and remove them.
Usage:
Code:
uTorrentAutomator.exe <address> <username> <password>
Example:
uTorrentAutomator.exe 192.168.1.1:5000 admin admin
Code:
uTorrentAutomator.exe <address> <username> <password> <Label> <Path To Torrent File>
Example:
uTorrentAutomator.exe 192.168.1.1:5000 admin admin TV %1
Will work inside of a Windows Batch file and will add the torrent called with it / dragged & dropped onto the batch file.
These are intended for use in a larger batch-driven scheme. I need to either write or find a "Directory Watcher" program which will trigger the download handler chains whenever new downloads complete.
My eventual handler chain will work like this:
TED will download torrents to some directory, which will automatically fire a batch script which uses uTorrentAutomator to add it to uTorrent + the TV label. The show will download to FinishedDownloads\TV, which will have a second directory watcher on it. The second one will fire a TV show manager batch tool, which will fire my uTorrentAutomator (for clearing the finished tasks), then probably TheRenamer, followed by another command-line tool I plan on writing which will call the "UpdateLibrary" function on my various installs of XBMC around the house.
I've got some other plans and welcome any feedback from you fine forum people
I have zipped and uploaded the app here. Its only 17K because its a command console / batch program. I haven't implemented any real error handling yet, so it will crash if it encounters a scenario it doesn't like.
If you guys have any other command-line program needs, I would be happy to throw something together for you, like 'take this filename, apply this RegEx to it and then spit the output back to the console". I'm sure we'll come up with some stuff. I also have some plans for implementing some other download handlers, mainly for the "Movies" label / download destination. Mostly the same as TV shows just with a few tweaks.
EDIT
Forgot to make sure its clear, this was made with C# and you will need the .NET Framework 3.5 installed. If you don't have it, its a free one time install, download here:
http://www.microsoft.com/downloads/detai...laylang=en