# HG changeset patch # User Thomas Arendsen Hein # Date 1183040289 -7200 # Node ID 8d4fac0a9df7670726d747f7e327c8f812b0895c # Parent 9ac493f12901327814e79a371f8175e5f8bfe376 Make hg glog abort if unused arguments are given. diff --git a/hgext/graphlog.py b/hgext/graphlog.py --- a/hgext/graphlog.py +++ b/hgext/graphlog.py @@ -141,7 +141,7 @@ def get_revs(repo, rev_opt): else: return (repo.changelog.count() - 1, 0) -def graphlog(ui, repo, *args, **opts): +def graphlog(ui, repo, **opts): """show revision history alongside an ASCII revision graph Print a revision history alongside a revision graph drawn with diff --git a/tests/test-glog b/tests/test-glog --- a/tests/test-glog +++ b/tests/test-glog @@ -138,3 +138,6 @@ hg glog -q echo % glog hg glog + +echo % unused arguments +hg glog -q foo || echo failed diff --git a/tests/test-glog.out b/tests/test-glog.out --- a/tests/test-glog.out +++ b/tests/test-glog.out @@ -307,3 +307,9 @@ o changeset: 0:7aa22e58e8c1 date: Thu Jan 01 00:00:00 1970 +0000 summary: (0) root +% unused arguments +hg glog: invalid arguments +hg glog [OPTION]... + +show revision history alongside an ASCII revision graph +failed