# HG changeset patch # User Artem Tikhomirov # Date 1374948937 -7200 # Node ID 1499139a600a20f2c36bf9b84a3efa9f0d29e621 # Parent 9859fcea475d36c4059fd7e0cb32b631855d9e16 Defect: copies are not reported with default settings (not even as added!). Parameter needCopies removed as there seems to be no reason to condition copies for hi-level api (HgStatus.isCopy() is way down the road) diff -r 9859fcea475d -r 1499139a600a cmdline/org/tmatesoft/hg/console/Status.java --- a/cmdline/org/tmatesoft/hg/console/Status.java Sat Jul 27 18:34:14 2013 +0200 +++ b/cmdline/org/tmatesoft/hg/console/Status.java Sat Jul 27 20:15:37 2013 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2010-2011 TMate Software Ltd + * Copyright (c) 2010-2013 TMate Software Ltd * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -44,7 +44,7 @@ public class Status { public static void main(String[] args) throws Exception { - final Set flagOpts = asSet("-A", "-all", "-m", "--modified", "-a", "--added", "-r", "--removed", + final Set flagOpts = asSet("-A", "--all", "-m", "--modified", "-a", "--added", "-r", "--removed", "--d", "--deleted", "-u", "--unknown", "-c", "--clean", "-i", "--ignored", "-n", "--no-status", "-C", "--copies"); Options cmdLineOpts = Options.parse(args, flagOpts); diff -r 9859fcea475d -r 1499139a600a src/org/tmatesoft/hg/core/HgStatusCommand.java --- a/src/org/tmatesoft/hg/core/HgStatusCommand.java Sat Jul 27 18:34:14 2013 +0200 +++ b/src/org/tmatesoft/hg/core/HgStatusCommand.java Sat Jul 27 20:15:37 2013 +0200 @@ -61,13 +61,13 @@ public HgStatusCommand defaults() { final Mediator m = mediator; m.needModified = m.needAdded = m.needRemoved = m.needUnknown = m.needMissing = true; - m.needCopies = m.needClean = m.needIgnored = false; + m.needClean = m.needIgnored = false; return this; } public HgStatusCommand all() { final Mediator m = mediator; m.needModified = m.needAdded = m.needRemoved = m.needUnknown = m.needMissing = true; - m.needCopies = m.needClean = m.needIgnored = true; + m.needClean = m.needIgnored = true; return this; } @@ -252,7 +252,6 @@ boolean needMissing; boolean needClean; boolean needIgnored; - boolean needCopies; HgStatusHandler handler; private ChangelogHelper logHelper; private HgCallbackTargetException failure; @@ -311,10 +310,8 @@ } } public void copied(Path fnameOrigin, Path fnameAdded) { - if (needCopies) { - // TODO post-1.0 in fact, merged files may report 'copied from' as well, correct status kind thus may differ from Added - dispatch(new HgStatus(Added, fnameAdded, fnameOrigin, logHelper)); - } + // TODO post-1.0 in fact, merged files may report 'copied from' as well, correct status kind thus may differ from Added + dispatch(new HgStatus(Added, fnameAdded, fnameOrigin, logHelper)); } public void missing(Path fname) { if (needMissing) {