mirror of
https://github.com/dbcli/pgcli
synced 2024-06-24 02:03:20 +00:00
Make completion menu sorted.
This commit is contained in:
parent
588be27797
commit
a31053aa1f
|
@ -122,7 +122,7 @@ class PGCompleter(Completer):
|
|||
@staticmethod
|
||||
def find_matches(text, collection):
|
||||
text = last_word(text, include='most_punctuations')
|
||||
for item in collection:
|
||||
for item in sorted(collection):
|
||||
if (item.startswith(text) or item.startswith(text.upper()) or
|
||||
item.startswith(text.lower())):
|
||||
yield Completion(item, -len(text))
|
||||
|
|
Loading…
Reference in New Issue
Block a user