# HG changeset patch # User Matt Mackall # Date 1158959559 18000 # Node ID 6719b3dd7d504606725ae172afccce93864aca68 # Parent a5e4c8172acedff548ff7ebe69b9540351306aea context: add __repr__ methods diff -r a5e4c8172ace -r 6719b3dd7d50 mercurial/context.py --- a/mercurial/context.py Fri Sep 22 16:01:14 2006 -0500 +++ b/mercurial/context.py Fri Sep 22 16:12:39 2006 -0500 @@ -28,6 +28,9 @@ self._node = self._repo.lookup(changeid) self._rev = self._repo.changelog.rev(self._node) + def __repr__(self): + return "" % short(self.node()) + def changeset(self): try: return self._changeset @@ -120,6 +123,9 @@ else: raise AttributeError, name + def __repr__(self): + return "" % (self.path(), short(self.node())) + def filerev(self): return self._filerev def filenode(self): return self._filenode def filelog(self): return self._filelog