Mercurial > jhg
diff cmdline/org/tmatesoft/hg/console/Main.java @ 253:1874d11054e5
HgLogCommand.changeset(Nodeid) to ease command configuration
author | Artem Tikhomirov <tikhomirov.artem@gmail.com> |
---|---|
date | Mon, 15 Aug 2011 18:59:05 +0200 |
parents | a6d19adc2636 |
children | a620f0663a37 |
line wrap: on
line diff
--- a/cmdline/org/tmatesoft/hg/console/Main.java Mon Aug 15 18:51:41 2011 +0200 +++ b/cmdline/org/tmatesoft/hg/console/Main.java Mon Aug 15 18:59:05 2011 +0200 @@ -163,15 +163,12 @@ // hg parents cmd final Pair<Nodeid, Nodeid> wcParents = hgRepo.getWorkingCopyParents(); ChangesetDumpHandler dump = new ChangesetDumpHandler(hgRepo); - final HgChangelog clog = hgRepo.getChangelog(); HgLogCommand cmd = new HgLogCommand(hgRepo); if (wcParents.hasFirst()) { - int x = clog.getLocalRevision(wcParents.first()); - cmd.range(x, x).execute(dump); // FIXME HgLogCommand shall support Nodeid as revisions + cmd.changeset(wcParents.first()).execute(dump); } if (wcParents.hasSecond()) { - int x = clog.getLocalRevision(wcParents.second()); - cmd.range(x, x).execute(dump); + cmd.changeset(wcParents.second()).execute(dump); } System.out.println("Branch:" + hgRepo.getWorkingCopyBranchName()); }