mirror of
https://git.deluge-torrent.org/deluge
synced 2025-08-02 22:48:40 +00:00
Add preliminary(Torrent ID/name only) autcompletion to manage command
This commit is contained in:
parent
1bc3c293fa
commit
314b6138d7
1 changed files with 6 additions and 0 deletions
|
@ -44,6 +44,8 @@ from deluge.log import LOG as log
|
||||||
|
|
||||||
from optparse import make_option
|
from optparse import make_option
|
||||||
|
|
||||||
|
import re
|
||||||
|
|
||||||
torrent_options = {
|
torrent_options = {
|
||||||
"max_download_speed": float,
|
"max_download_speed": float,
|
||||||
"max_upload_speed": float,
|
"max_upload_speed": float,
|
||||||
|
@ -132,3 +134,7 @@ class Command(BaseCommand):
|
||||||
self.console.write("Setting %s to %s for torrents %s.." % (key, val, torrent_ids))
|
self.console.write("Setting %s to %s for torrents %s.." % (key, val, torrent_ids))
|
||||||
client.core.set_torrent_options(torrent_ids, {key: val}).addCallback(on_set_config)
|
client.core.set_torrent_options(torrent_ids, {key: val}).addCallback(on_set_config)
|
||||||
return deferred
|
return deferred
|
||||||
|
|
||||||
|
def complete(self, line):
|
||||||
|
# We use the ConsoleUI torrent tab complete method
|
||||||
|
return component.get("ConsoleUI").tab_complete_torrent(line)
|
Loading…
Add table
Add a link
Reference in a new issue