Patchwork [30,of,35] graphlog: define inferrepo in command decorator

login
register
mail settings
Submitter Gregory Szorc
Date May 5, 2014, 5:51 a.m.
Message ID <9a7249952af9dbe31fc5.1399269095@vm-ubuntu-main.gateway.sonic.net>
Download mbox | patch
Permalink /patch/4621/
State Accepted
Commit 404eca1ce4f91aa6f7ff026272c6a85cb268996f
Headers show

Comments

Gregory Szorc - May 5, 2014, 5:51 a.m.
# HG changeset patch
# User Gregory Szorc <gregory.szorc@gmail.com>
# Date 1399267726 25200
#      Sun May 04 22:28:46 2014 -0700
# Branch stable
# Node ID 9a7249952af9dbe31fc5b922b7d275da07b4fe5f
# Parent  75277696df23760fdcc7fd94c0d192e920a2c73f
graphlog: define inferrepo in command decorator

Patch

diff --git a/hgext/graphlog.py b/hgext/graphlog.py
--- a/hgext/graphlog.py
+++ b/hgext/graphlog.py
@@ -38,21 +38,20 @@  testedwith = 'internal'
     ('', 'only-branch', [],
      _('show only changesets within the given named branch (DEPRECATED)'),
      _('BRANCH')),
     ('b', 'branch', [],
      _('show changesets within the given named branch'), _('BRANCH')),
     ('P', 'prune', [],
      _('do not display revision or any of its ancestors'), _('REV')),
     ] + commands.logopts + commands.walkopts,
-    _('[OPTION]... [FILE]'))
+    _('[OPTION]... [FILE]'),
+    inferrepo=True)
 def graphlog(ui, repo, *pats, **opts):
     """show revision history alongside an ASCII revision graph
 
     Print a revision history alongside a revision graph drawn with
     ASCII characters.
 
     Nodes printed as an @ character are parents of the working
     directory.
     """
     return cmdutil.graphlog(ui, repo, *pats, **opts)
-
-commands.inferrepo += " glog"