From patchwork Mon Sep 19 23:24:56 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: [1,of,2] copy: document current behavior of 'hg cp --after' From: Augie Fackler X-Patchwork-Id: 16681 Message-Id: <0ee023b61175e76d5172.1474327496@augie-macbookair2.roam.corp.google.com> To: mercurial-devel@mercurial-scm.org Date: Mon, 19 Sep 2016 19:24:56 -0400 # HG changeset patch # User Augie Fackler # Date 1474319683 14400 # Mon Sep 19 17:14:43 2016 -0400 # Node ID 0ee023b61175e76d51726a51c09af6fccf1e8846 # Parent e40343ce9c4c4819ea5669abb3447d5c031a8270 copy: document current behavior of 'hg cp --after' I'm about to propose an output change here, but the existing behavior was untested! diff --git a/tests/test-copy.t b/tests/test-copy.t --- a/tests/test-copy.t +++ b/tests/test-copy.t @@ -224,6 +224,9 @@ copy --after on an added file foo was clean: $ hg st -AC foo C foo +Trying to copy on top of an existing file fails, + $ hg copy -A bar foo + foo: not overwriting - file exists but it's considered modified after a copy --after --force $ hg copy -Af bar foo $ hg st -AC foo