Win10 script torrent complete not running .exe's

Ask for help and report issues with the Windows version of Transmission
Post Reply
daves_27@hotmail.com
Posts: 1
Joined: Wed Sep 25, 2019 6:09 pm

Win10 script torrent complete not running .exe's

Post by daves_27@hotmail.com » Wed Sep 25, 2019 6:59 pm

Hello,

I am unable to run transmission-remote.exe from within my torrent complete .bat script. I have previous linux experience with transmission executing shell scripts when torrents are complete. I have tried transmission 2.94 x86 & x64 versions on Windows 10 with no luck and latest stable build with no luck either.

Within my script I am able to create sample txt files (torrent_complete_1 & 2) but when the .exe is run the ERRORLEVEL is 1. I'm not quite sure why. I've been reading the forums and it seems like folks are able to perform various operations on the torrents. I have tested unsuccessfully for transmission running as a local service and as an admin user with no luck.

Any help would be much appreciated!

Code: Select all

"script-torrent-done-filename": "C:\\test\\TorrentComplete.bat",
TorrentComplete.bat:

Code: Select all

@echo off
echo "test" > "C:\test\torrent_complete_1.txt"
echo %TR_TORRENT_ID% > "C:\test\torrent_complete_2.txt"
CALL "D:\Program Files\Transmission\transmission-remote" -l
IF %ERRORLEVEL% NEQ 0 (
    echo %ERRORLEVEL% > "C:\test\torrent_complete_error.txt"
)
CALL "D:\Program Files\Transmission\transmission-remote" -torrent %TR_TORRENT_ID% --stop
IF %ERRORLEVEL% NEQ 0 (
    echo %ERRORLEVEL% >> "C:\test\torrent_complete_error.txt"
)

Vargas
Posts: 1
Joined: Mon Jun 29, 2020 7:44 am

Re: Win10 script torrent complete not running .exe's

Post by Vargas » Mon Jun 29, 2020 7:47 am

I got same issue. Trying to run a bat file when torrent completes, but it's not run.
Using Transmission 3.00.
Anyone got it working?

mike.dld
Transmission Developer
Posts: 283
Joined: Wed Dec 25, 2013 10:56 pm

Re: Win10 script torrent complete not running .exe's

Post by mike.dld » Mon Jun 29, 2020 9:09 pm

Read my comment (and maybe the whole thread) on GitHub for pointers: https://github.com/transmission/transmi ... -472212932

mike.dld
Transmission Developer
Posts: 283
Joined: Wed Dec 25, 2013 10:56 pm

Re: Win10 script torrent complete not running .exe's

Post by mike.dld » Mon Jun 29, 2020 9:20 pm

To the OP, if you still have this issue consider redirecting the transmission-remote output to a file as well, e.g.

Code: Select all

CALL "D:\Program Files\Transmission\transmission-remote" -l > C:\test\output.log 2>&1

Post Reply