From patchwork Wed Mar 4 15:23:21 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: graphlog: do not bypass commands.log so that -fr works From: Yuya Nishihara X-Patchwork-Id: 7902 Message-Id: <6bd01a0f2eb263a08480.1425482601@mimosa> To: mercurial-devel@selenic.com Date: Thu, 05 Mar 2015 00:23:21 +0900 # HG changeset patch # User Yuya Nishihara # Date 1425473227 -32400 # Wed Mar 04 21:47:07 2015 +0900 # Node ID 6bd01a0f2eb263a08480057040caaaaecfa2187c # Parent 390410a6545d9088dc84392009f51500e3935a1c graphlog: do not bypass commands.log so that -fr works Since 8b4b9ee6001a, opts dict can be modified in commands.log() before calling cmdutil.graphlog(). diff --git a/hgext/graphlog.py b/hgext/graphlog.py --- a/hgext/graphlog.py +++ b/hgext/graphlog.py @@ -54,4 +54,5 @@ def graphlog(ui, repo, *pats, **opts): Nodes printed as an @ character are parents of the working directory. """ - return cmdutil.graphlog(ui, repo, *pats, **opts) + opts['graph'] = True + return commands.log(ui, repo, *pats, **opts) diff --git a/tests/test-glog.t b/tests/test-glog.t --- a/tests/test-glog.t +++ b/tests/test-glog.t @@ -2243,6 +2243,14 @@ Test --follow-first and backward --rev ('symbol', 'rev') ('symbol', '6')))) +Test --follow with --rev of graphlog extension + + $ hg --config extensions.graphlog= glog -qfr1 + o 1:216d4c92cf98 + | + o 0:f8035bb17114 + + Test subdir $ hg up -q 3