I'm trying to make a script in bash (first time) for the Deluge plugin execute so after a download is complete it will change the permissions of the downloaded torrent.
its:
#!bin/bash
torrentpath=$3
sudo chmod -R 777 $torrentpath
Also tried with $torrentpath in "", didnt work either. Copied the first 2 lines from the plugins wiki page (https://dev.deluge-torrent.org/wiki/Plugins/Execute).
Any idea how to make it work?