comparison mercurial/context.py @ 3313:6c68bc1e7873

context: change workingctx str() from . to <node>+
author Matt Mackall <mpm@selenic.com>
date Tue, 10 Oct 2006 02:11:59 -0500
parents 0e370798eebf
children 50a18815e3f0 e44eadc92ec4
comparison
equal deleted inserted replaced
3312:c5075ad5e3e9 3313:6c68bc1e7873
328 self._repo = repo 328 self._repo = repo
329 self._rev = None 329 self._rev = None
330 self._node = None 330 self._node = None
331 331
332 def __str__(self): 332 def __str__(self):
333 return "." 333 return str(self._parents[0]) + "+"
334 334
335 def __nonzero__(self): 335 def __nonzero__(self):
336 return True 336 return True
337 337
338 def __getattr__(self, name): 338 def __getattr__(self, name):
428 428
429 def __nonzero__(self): 429 def __nonzero__(self):
430 return True 430 return True
431 431
432 def __str__(self): 432 def __str__(self):
433 return "%s@." % self.path() 433 return "%s@%s" % (self.path(), self._changectx)
434 434
435 def filectx(self, fileid): 435 def filectx(self, fileid):
436 '''opens an arbitrary revision of the file without 436 '''opens an arbitrary revision of the file without
437 opening a new filelog''' 437 opening a new filelog'''
438 return filectx(self._repo, self._repopath, fileid=fileid, 438 return filectx(self._repo, self._repopath, fileid=fileid,