mercurial/commands.py
changeset 24432 e22248f6d257
parent 24429 69bd0ec2f9be
child 24455 16961d43dc89
--- a/mercurial/commands.py	Tue Mar 17 15:06:40 2015 -0700
+++ b/mercurial/commands.py	Tue Mar 17 15:46:30 2015 -0700
@@ -148,6 +148,7 @@
     ('U', 'unified', '',
      _('number of lines of context to show'), _('NUM')),
     ('', 'stat', None, _('output diffstat-style summary of changes')),
+    ('', 'relative', '', _('produce diffs relative to subdirectory'), _('DIR')),
 ]
 
 mergetoolopts = [
@@ -3169,7 +3170,8 @@
     diffopts = patch.diffallopts(ui, opts)
     m = scmutil.match(repo[node2], pats, opts)
     cmdutil.diffordiffstat(ui, repo, diffopts, node1, node2, m, stat=stat,
-                           listsubrepos=opts.get('subrepos'))
+                           listsubrepos=opts.get('subrepos'),
+                           relative=opts.get('relative'))
 
 @command('^export',
     [('o', 'output', '',