Jump to content

Proper States for "Torrent done downloading"


Recommended Posts

So, please forgive me if this has been asked before or if I'm posting in the incorrect section...

I am trying to create a simple batch script that runs when a torrent's state completes to copy downloads to a specific location...without having to use labels.  

My setup is as follows ->


1.  Downloading torrents live in D:\downloading

2.  Completed torrents live in D:\downloads.  This is just so I always know which downloads are complete and what are still going.

3.  Torrent changes state, following command is executed:

D:\justcopy.cmd "%N" %S %P %M


4.  Justcopy does the following:


@echo offecho %1 echo current state is %2echo previous state is %3echo status is %4IF %2==5 ( goto dropit )echo State not matched, terminating.goto finish :dropitecho State matched, dropping file.C:\Progra~1\DropIt\Dropit.exe "D:\downloads\%~1" :finishpause


5.  Dropit runs, and sorts the download according to the filename.


Now, ideally, I'd like to have it set up so that if the previous state was 6 (downloading) and it goes to 5 (seeding), it knows it's just finished downloading - versus Utorrent starting up on a reboot or something - and drops the file.



But, as I've seen from watching the different state changes, it rarely runs on changing to "seeding", even without checking the previous state.  

So, any ideas what states I should be checking for to find the condition of "it just finished downloading"??

Link to comment
Share on other sites


This topic is now archived and is closed to further replies.

  • Create New...