diff options
author | Amjith Ramanujam <amjith.r@gmail.com> | 2015-01-29 13:32:42 -0800 |
---|---|---|
committer | Amjith Ramanujam <amjith.r@gmail.com> | 2015-01-29 13:54:07 -0800 |
commit | c08d4a51e5540e7ada833bd4beb6ba2f4bdba37e (patch) | |
tree | e9d95c9894e46f86c0b989feaada50c78d60ea1b | |
parent | 3ed89e01e495c122283053c3a91d752d0d70abce (diff) |
Make completions case-insensitive
-rw-r--r-- | pgcli/pgcompleter.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/pgcli/pgcompleter.py b/pgcli/pgcompleter.py index 3585abeb..daaf1673 100644 --- a/pgcli/pgcompleter.py +++ b/pgcli/pgcompleter.py @@ -123,7 +123,8 @@ class PGCompleter(Completer): def find_matches(text, collection): text = last_word(text, include='most_punctuations') for item in collection: - if item.startswith(text) or item.startswith(text.upper()): + if (item.startswith(text) or item.startswith(text.upper()) or + item.startswith(text.lower())): yield Completion(item, -len(text)) def get_completions(self, document, complete_event, smart_completion=None): |