summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authormathieui <mathieui@mathieui.net>2014-12-09 16:56:43 +0100
committermathieui <mathieui@mathieui.net>2014-12-09 16:56:43 +0100
commitbbc79e089d9832071fe5ca7f56a5505a3ab7661b (patch)
tree50a99dbc21510ca343efb666e310e1d3c16ad25c /src
parent2e25595aec8c80cb2979acba50604345b79c1170 (diff)
downloadpoezio-bbc79e089d9832071fe5ca7f56a5505a3ab7661b.tar.gz
poezio-bbc79e089d9832071fe5ca7f56a5505a3ab7661b.tar.bz2
poezio-bbc79e089d9832071fe5ca7f56a5505a3ab7661b.tar.xz
poezio-bbc79e089d9832071fe5ca7f56a5505a3ab7661b.zip
Fix #2842 (complete all existing options with /set-completion)
Diffstat (limited to 'src')
-rw-r--r--src/core/completions.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/core/completions.py b/src/core/completions.py
index a8d695d1..612144f6 100644
--- a/src/core/completions.py
+++ b/src/core/completions.py
@@ -304,7 +304,10 @@ def completion_set(self, the_input):
plugin = self.plugin_manager.plugins[plugin_name]
end_list = ['%s|%s' % (plugin_name, section) for section in plugin.config.sections()]
else:
- end_list = config.options('Poezio')
+ end_list = set(config.options('Poezio'))
+ end_list = end_list.union(set(config.default.get('Poezio', {})))
+ end_list = list(end_list)
+ end_list.sort()
elif n == 2:
if '|' in args[1]:
plugin_name, section = args[1].split('|')[:2]