Changeset 3187
- Timestamp:
- 02/06/08 09:49:01 (10 months ago)
- Files:
-
- gitplugin/0.11/gitplugin/git_fs.py (modified) (1 diff)
- gitplugin/0.11/gitplugin/PyGIT.py (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
gitplugin/0.11/gitplugin/git_fs.py
r3185 r3187 152 152 return GitNode(self.git, path, rev) 153 153 154 def get_quickjump_entries(self, rev): 155 for bname,bsha in self.git.get_branches(): 156 yield 'branches', bname, '/', bsha 157 for t in self.git.get_tags(): 158 yield 'tags', t, '/', t 159 154 160 def get_changesets(self, start, stop): 155 161 #print "get_changesets", start, stop gitplugin/0.11/gitplugin/PyGIT.py
r3185 r3187 234 234 235 235 def get_branches(self): 236 "returns list of branches, with active ( i.e.HEAD) one being the first item"236 "returns list of branches, with active (= HEAD) one being the first item" 237 237 result=[] 238 for e in self._git_call_f("git-branch ").readlines():239 bname=e[1:].strip()238 for e in self._git_call_f("git-branch -v --no-abbrev").readlines(): 239 (bname,bsha)=e[1:].strip().split()[:2] 240 240 if e[0]=='*': 241 result.insert(0, bname)241 result.insert(0,(bname,bsha)) 242 242 else: 243 result.append(bname) 243 result.append((bname,bsha)) 244 return result 245 246 def get_tags(self): 247 result=[] 248 for e in self._git_call_f("git-tag -l").readlines(): 249 result.append(e.strip()) 244 250 return result 245 251 … … 357 363 358 364 if __name__ == '__main__': 359 import sys 360 361 g = Storage(sys.argv[1] )365 import sys, logging 366 367 g = Storage(sys.argv[1], logging) 362 368 363 369 print "[%s]" % g.head()
