mercurial/commands.py
changeset 10957 0d5f139b23c1
parent 10934 a8486615eece
child 10958 021d5ac3bec0
--- a/mercurial/commands.py	Sat Apr 17 14:32:26 2010 +0200
+++ b/mercurial/commands.py	Sun Apr 18 18:18:19 2010 -0400
@@ -2157,6 +2157,8 @@
     if opts["date"]:
         df = util.matchdate(opts["date"])
 
+    opts['branch'] += opts.get('only_branch')
+
     displayer = cmdutil.show_changeset(ui, repo, opts, True, matchfn)
     def prep(ctx, fns):
         rev = ctx.rev()
@@ -2166,7 +2168,7 @@
             return
         if opts.get('only_merges') and len(parents) != 2:
             return
-        if opts.get('only_branch') and ctx.branch() not in opts['only_branch']:
+        if opts.get('branch') and ctx.branch() not in opts['branch']:
             return
         if df and not df(ctx.date()[0]):
             return
@@ -3739,8 +3741,10 @@
           ('', 'removed', None, _('include revisions where files were removed')),
           ('m', 'only-merges', None, _('show only merges')),
           ('u', 'user', [], _('revisions committed by user')),
-          ('b', 'only-branch', [],
-            _('show only changesets within the given named branch')),
+          ('', 'only-branch', [],
+            _('show only changesets within the given named branch (DEPRECATED)')),
+          ('b', 'branch', [],
+            _('show changesets within the given named branch')),
           ('P', 'prune', [],
            _('do not display revision or any of its ancestors')),
          ] + logopts + walkopts,