Show More
@@ -204,13 +204,15 b' class changectx(object):' | |||||
204 | def sub(self, path): |
|
204 | def sub(self, path): | |
205 | return subrepo.subrepo(self, path) |
|
205 | return subrepo.subrepo(self, path) | |
206 |
|
206 | |||
207 | def diff(self, ctx2=None, match=None): |
|
207 | def diff(self, ctx2=None, match=None, opts=None): | |
208 | """Returns a diff generator for the given contexts and matcher""" |
|
208 | """Returns a diff generator for the given contexts and matcher""" | |
209 | if ctx2 is None: |
|
209 | if ctx2 is None: | |
210 | ctx2 = self.p1() |
|
210 | ctx2 = self.p1() | |
211 | if ctx2 is not None and not isinstance(ctx2, changectx): |
|
211 | if ctx2 is not None and not isinstance(ctx2, changectx): | |
212 | ctx2 = self._repo[ctx2] |
|
212 | ctx2 = self._repo[ctx2] | |
213 | return patch.diff(self._repo, ctx2.node(), self.node(), match=match) |
|
213 | diffopts = patch.diffopts(self._repo.ui, opts) | |
|
214 | return patch.diff(self._repo, ctx2.node(), self.node(), | |||
|
215 | match=match, opts=diffopts) | |||
214 |
|
216 | |||
215 | class filectx(object): |
|
217 | class filectx(object): | |
216 | """A filecontext object makes access to data related to a particular |
|
218 | """A filecontext object makes access to data related to a particular |
General Comments 0
You need to be logged in to leave comments.
Login now