##// END OF EJS Templates
import completer: only crippled 'local' version for py 2.4
vivainio -
Show More
@@ -12,7 +12,7 b' update upgrade'
12
12
13 """
13 """
14 import IPython.ipapi
14 import IPython.ipapi
15 import glob,os,shlex
15 import glob,os,shlex,sys
16
16
17 ip = IPython.ipapi.get()
17 ip = IPython.ipapi.get()
18
18
@@ -50,6 +50,12 b' pkg_cache = None'
50 def module_completer(self,event):
50 def module_completer(self,event):
51 """ Give completions after user has typed 'import' """
51 """ Give completions after user has typed 'import' """
52
52
53 # only a local version for py 2.4, pkgutil has no walk_packages() there
54 if sys.version_info < (2,5):
55 for el in [f[:-3] for f in glob.glob("*.py")]:
56 yield el
57 return
58
53 global pkg_cache
59 global pkg_cache
54 import pkgutil,imp,time
60 import pkgutil,imp,time
55 #current =
61 #current =
General Comments 0
You need to be logged in to leave comments. Login now