Using Execute with Powershell?

Specific support for Deluge on Microsoft Windows OS
Post Reply
darkness5723

Using Execute with Powershell?

Post by darkness5723 »

Okay, so I've been trying to use Powershell with the Execute plugin, because it's my main scripting language. I could just use Python, but at this point it's mostly stubbornness. No matter what I try though I can't get it to work. If I try just the script path I get this error:

Code: Select all

Event handler TorrentFinishedEvent failed in <function event_handler at 0x024EB370> with exception 'C:\\Powershell\\ProcessTorrent.ps1' is neither a Windows executable, nor a script with a shebang line
Then, if I try to call powershell.exe with arguments (powershell.exe -File "C:\powershell\processtorrent.ps1"), or any variation thereof, I get this:

Code: Select all

Event handler TorrentFinishedEvent failed in <function event_handler at 0x024EB370> with exception (123, 'CreateProcess', 'The filename, directory name, or volume label syntax is incorrect.')
Is there something I'm missing here?
Cas
Top Bloke
Top Bloke
Posts: 3681
Joined: Mon Dec 07, 2009 6:04 am
Location: Scotland

Re: Using Execute with Powershell?

Post by Cas »

You only supply execute plugin with a script path and it has to be executable type, such as a `.cmd` script.
Post Reply