##// END OF EJS Templates
cd - now has completions too (show directory history entries)
vivainio -
Show More
@@ -114,7 +114,15 b' def listdirs(self, event):'
114 # return only bookmark completions
114 # return only bookmark completions
115 bkms = self.db.get('bookmarks',{})
115 bkms = self.db.get('bookmarks',{})
116 return bkms.keys()
116 return bkms.keys()
117
118 if event.symbol == '-':
119 # jump in directory history by number
120 ents = ['-%d [%s]' % (i,s) for i,s in enumerate(ip.user_ns['_dh'])]
121 if len(ents) > 1:
122 return ents
123 return []
117
124
125
118 if relpath.startswith('~'):
126 if relpath.startswith('~'):
119 relpath = os.path.expanduser(relpath).replace('\\','/')
127 relpath = os.path.expanduser(relpath).replace('\\','/')
120 found = [f.replace('\\','/')+'/' for f in glob.glob(relpath+'*') if os.path.isdir(f)]
128 found = [f.replace('\\','/')+'/' for f in glob.glob(relpath+'*') if os.path.isdir(f)]
General Comments 0
You need to be logged in to leave comments. Login now