Code: Select all
perl -pi -w -e 's/THIS/THAT/g;' /path/to/files*.txt
Code: Select all
perl -pi -w -e 's/THIS/THAT/g;' /path/to/files*.txt
Sorry for the necrobump but hoping someone might be able to help me get this script to work.
I don't know anything about python or programming and despite my best efforts this has me stumped.Traceback (most recent call last):
File "deluge_tracker_rename.py", line 39, in <module>
state = cPickle.load(state_file)
ImportError: No module named deluge.core.torrentmanager
Code: Select all
#Create Deluge profile backup
$SOURCE = "$env:appdata\deluge"
$BACKUP = "$env:appdata\deluge.backup"
New-Item -ItemType "directory" -Path $BACKUP -force | out-null
Copy-Item -R -Path $SOURCE -Destination $BACKUP -force
Code: Select all
const trackers = [{"tier":0,"url":"http://tracker.url"}]
ids = deluge.torrents.getSelectedIds();
ids.forEach(id => {
deluge.client.core.set_torrent_trackers(id, trackers, {
failure: () => console.warn(`Failed to update ${id}`)
});
})