Mercurial > public > mercurial-scm > hg
diff mercurial/cmdutil.py @ 17182:cdf1532d89c6
incoming/outgoing: handle --graph in core
author | Patrick Mezard <patrick@mezard.eu> |
---|---|
date | Wed, 11 Jul 2012 18:22:07 +0200 |
parents | 6f71167292f2 |
children | afd75476939e |
line wrap: on
line diff
--- a/mercurial/cmdutil.py Sat Jul 14 19:09:22 2012 +0200 +++ b/mercurial/cmdutil.py Wed Jul 11 18:22:07 2012 +0200 @@ -1450,6 +1450,19 @@ displaygraph(ui, revdag, displayer, showparents, graphmod.asciiedges, getrenamed, filematcher) +def checkunsupportedgraphflags(pats, opts): + for op in ["newest_first"]: + if op in opts and opts[op]: + raise util.Abort(_("-G/--graph option is incompatible with --%s") + % op.replace("_", "-")) + +def graphrevs(repo, nodes, opts): + limit = loglimit(opts) + nodes.reverse() + if limit is not None: + nodes = nodes[:limit] + return graphmod.nodes(repo, nodes) + def add(ui, repo, match, dryrun, listsubrepos, prefix, explicitonly): join = lambda f: os.path.join(prefix, f) bad = []