comparison mercurial/localrepo.py @ 3203:14792adabf80

Merge with upstream
author Thomas Arendsen Hein <thomas@intevation.de>
date Sat, 30 Sep 2006 09:46:03 +0200
parents ff15ba23c1cf
children 53e843840349 8d4855fd9d7b
comparison
equal deleted inserted replaced
3195:f8e67b7c57a4 3203:14792adabf80
318 f = f[1:] 318 f = f[1:]
319 return filelog.filelog(self.opener, f, self.revlogversion) 319 return filelog.filelog(self.opener, f, self.revlogversion)
320 320
321 def changectx(self, changeid=None): 321 def changectx(self, changeid=None):
322 return context.changectx(self, changeid) 322 return context.changectx(self, changeid)
323
324 def parents(self, changeid=None):
325 '''
326 get list of changectxs for parents of changeid or working directory
327 '''
328 if changeid is None:
329 pl = self.dirstate.parents()
330 else:
331 n = self.changelog.lookup(changeid)
332 pl = self.changelog.parents(n)
333 if pl[1] == nullid:
334 return [self.changectx(pl[0])]
335 return [self.changectx(pl[0]), self.changectx(pl[1])]
323 336
324 def filectx(self, path, changeid=None, fileid=None): 337 def filectx(self, path, changeid=None, fileid=None):
325 """changeid can be a changeset revision, node, or tag. 338 """changeid can be a changeset revision, node, or tag.
326 fileid can be a file revision or node.""" 339 fileid can be a file revision or node."""
327 return context.filectx(self, path, changeid, fileid) 340 return context.filectx(self, path, changeid, fileid)