From f25e889d768aceb6732cbfd39b91194f81b35d78 2006-11-02 10:01:39 From: vivainio Date: 2006-11-02 10:01:39 Subject: [PATCH] install stock completers in default user config. Ignore case in filtering possible custom completions --- diff --git a/IPython/UserConfig/ipy_user_conf.py b/IPython/UserConfig/ipy_user_conf.py index d552567..df8dbfd 100644 --- a/IPython/UserConfig/ipy_user_conf.py +++ b/IPython/UserConfig/ipy_user_conf.py @@ -23,6 +23,10 @@ ip = IPython.ipapi.get() # import ipy_defaults def main(): + # Handy tab-completers for %cd, %run, import etc. + # Try commenting this out if you have completion problems/slowness + import ipy_stock_completers + o = ip.options # An example on how to set options #o.autocall = 1 diff --git a/IPython/completer.py b/IPython/completer.py index 1ea29b1..f26a8fb 100644 --- a/IPython/completer.py +++ b/IPython/completer.py @@ -557,7 +557,7 @@ class IPCompleter(Completer): # print "try",c # dbg try: res = c(event) - return [r for r in res if r.startswith(text)] + return [r for r in res if r.lower().startswith(text.lower())] except ipapi.TryNext: pass diff --git a/doc/ChangeLog b/doc/ChangeLog index cfe25cd..04dbc3b 100644 --- a/doc/ChangeLog +++ b/doc/ChangeLog @@ -3,7 +3,11 @@ * ipy_stock_completers.py: Add %run and %cd completers. * completer.py: Try running custom completer for both - "foo" and "%foo" if the command is just "foo". + "foo" and "%foo" if the command is just "foo". Ignore case + when filtering possible completions. + + * UserConfig/ipy_user_conf.py: install stock completers as default + 2006-10-31 Ville Vainio