Trying to run a .bat file when torrent completes

Specific support for Deluge on Microsoft Windows OS
Cas
Top Bloke
Top Bloke
Posts: 3681
Joined: Mon Dec 07, 2009 6:04 am
Location: Scotland

Re: Trying to run a .bat file when torrent completes

Post by Cas »

You clearly don't understand batch because you are making fundamental mistakes. The code I posted is a working batch file, just test that and nothing else.
ambreswe
Member
Member
Posts: 21
Joined: Wed Aug 13, 2014 10:50 pm

Re: Trying to run a .bat file when torrent completes

Post by ambreswe »

Cas wrote:You clearly don't understand batch because you are making fundamental mistakes. The code I posted is a working batch file, just test that and nothing else.
Well, yes and no, I'm not sure why I thought batch would handle variables like bash do... my bad.
I'll test again with the correct variables.
ambreswe
Member
Member
Posts: 21
Joined: Wed Aug 13, 2014 10:50 pm

Re: Trying to run a .bat file when torrent completes

Post by ambreswe »

Ok, fixed my mistakes, thanks for that, must've been tired last night.

Code: Select all

@echo off
set torrentid=%1
set torrentname=%2
set torrentpath=%3
@echo Torrent Details: %torrentname% %torrentpath% %torrentid%  >> D:\deluge_exec.log
Doesn't work.
Copied yours, doesn't work :(

Could this be a win8.1 thing?
PeeLoW

Re: Trying to run a .bat file when torrent completes

Post by PeeLoW »

HI
I'm also having this issue when trying to execute the simple bat example within deluge.
ambreswe
Member
Member
Posts: 21
Joined: Wed Aug 13, 2014 10:50 pm

Re: Trying to run a .bat file when torrent completes

Post by ambreswe »

I did do some mistakes to begin with, but I've also copied Cas example and it doesn't work, but now, I think I'm being ignored... :(
Cas
Top Bloke
Top Bloke
Posts: 3681
Joined: Mon Dec 07, 2009 6:04 am
Location: Scotland

Re: Trying to run a .bat file when torrent completes

Post by Cas »

It could be a win8.1 thing... It worked fine for me on Win XP but you could try a different path, such as user dir.
ambreswe
Member
Member
Posts: 21
Joined: Wed Aug 13, 2014 10:50 pm

Re: Trying to run a .bat file when torrent completes

Post by ambreswe »

Cas wrote:It could be a win8.1 thing... It worked fine for me on Win XP but you could try a different path, such as user dir.
I think I also tried putting the script in the Deluge install path before, could try that again, do I still need the whole path? or can I just point to "script.bat" ?

Cheers.
ambreswe
Member
Member
Posts: 21
Joined: Wed Aug 13, 2014 10:50 pm

Re: Trying to run a .bat file when torrent completes

Post by ambreswe »

ambreswe wrote:
Cas wrote:It could be a win8.1 thing... It worked fine for me on Win XP but you could try a different path, such as user dir.
I think I also tried putting the script in the Deluge install path before, could try that again, do I still need the whole path? or can I just point to "script.bat" ?

Cheers.
Tried, doesn't work, I put the script in: C:\Program Files (x86)\Deluge
Any chance you can try this under win8.1?
I really likes Deluge, but this is kind of a showstopper... :-/
Cas
Top Bloke
Top Bloke
Posts: 3681
Joined: Mon Dec 07, 2009 6:04 am
Location: Scotland

Re: Trying to run a .bat file when torrent completes

Post by Cas »

Not the script, the path where the log file is created...
ambreswe
Member
Member
Posts: 21
Joined: Wed Aug 13, 2014 10:50 pm

Re: Trying to run a .bat file when torrent completes

Post by ambreswe »

Cas wrote:Not the script, the path where the log file is created...
Any extra logging in Deluge I can turn on to see if the script actually runs at all? or if it fails for some reason even before that?
Post Reply