Mercurial > hg
annotate tests/test-copy.t @ 48926:3d35e7483602
manifest: remove pycompat.iteritems()
Differential Revision: https://phab.mercurial-scm.org/D12331
author | Gregory Szorc <gregory.szorc@gmail.com> |
---|---|
date | Mon, 21 Feb 2022 11:11:27 -0700 |
parents | 5ffc6c18fb96 |
children | ccd76e292be5 |
rev | line source |
---|---|
16856
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
1 $ mkdir part1 |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
2 $ cd part1 |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
3 |
11805
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
4 $ hg init |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
5 $ echo a > a |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
6 $ hg add a |
12156
4c94b6d0fb1c
tests: remove unneeded -d flags
Martin Geisler <mg@lazybytes.net>
parents:
11805
diff
changeset
|
7 $ hg commit -m "1" |
11805
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
8 $ hg status |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
9 $ hg copy a b |
13962
8b252e826c68
add: introduce a warning message for non-portable filenames (issue2756) (BC)
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
10 $ hg --config ui.portablefilenames=abort copy a con.xml |
33798
2cd5aba5e1d2
scmutil: use util.shellquote instead of %r
Augie Fackler <augie@google.com>
parents:
33425
diff
changeset
|
11 abort: filename contains 'con', which is reserved on Windows: con.xml |
45844
3175b0e0058b
errors: use InputError for errors about bad paths
Martin von Zweigbergk <martinvonz@google.com>
parents:
45827
diff
changeset
|
12 [10] |
11805
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
13 $ hg status |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
14 A b |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
15 $ hg sum |
12156
4c94b6d0fb1c
tests: remove unneeded -d flags
Martin Geisler <mg@lazybytes.net>
parents:
11805
diff
changeset
|
16 parent: 0:c19d34741b0a tip |
11805
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
17 1 |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
18 branch: default |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
19 commit: 1 copied |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
20 update: (current) |
25382
6084926366b9
summary: move the parents phase marker to commit line (issue4688)
Gilles Moris <gilles.moris@free.fr>
parents:
25111
diff
changeset
|
21 phases: 1 draft |
12156
4c94b6d0fb1c
tests: remove unneeded -d flags
Martin Geisler <mg@lazybytes.net>
parents:
11805
diff
changeset
|
22 $ hg --debug commit -m "2" |
23749
a387b0390082
localrepo: show headline notes in commitctx before showing filenames
Mads Kiilerich <madski@unity3d.com>
parents:
23285
diff
changeset
|
23 committing files: |
11805
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
24 b |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
25 b: copy a:b789fdd96dc2f3bd229c1dd8eedf0fc60e2b68e3 |
23749
a387b0390082
localrepo: show headline notes in commitctx before showing filenames
Mads Kiilerich <madski@unity3d.com>
parents:
23285
diff
changeset
|
26 committing manifest |
a387b0390082
localrepo: show headline notes in commitctx before showing filenames
Mads Kiilerich <madski@unity3d.com>
parents:
23285
diff
changeset
|
27 committing changelog |
32267
c2380b448265
caches: move the 'updating the branch cache' message in 'updatecaches'
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
30151
diff
changeset
|
28 updating the branch cache |
12156
4c94b6d0fb1c
tests: remove unneeded -d flags
Martin Geisler <mg@lazybytes.net>
parents:
11805
diff
changeset
|
29 committed changeset 1:93580a2c28a50a56f63526fb305067e6fbf739c4 |
11805
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
30 |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
31 we should see two history entries |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
32 |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
33 $ hg history -v |
12156
4c94b6d0fb1c
tests: remove unneeded -d flags
Martin Geisler <mg@lazybytes.net>
parents:
11805
diff
changeset
|
34 changeset: 1:93580a2c28a5 |
11805
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
35 tag: tip |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
36 user: test |
12156
4c94b6d0fb1c
tests: remove unneeded -d flags
Martin Geisler <mg@lazybytes.net>
parents:
11805
diff
changeset
|
37 date: Thu Jan 01 00:00:00 1970 +0000 |
11805
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
38 files: b |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
39 description: |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
40 2 |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
41 |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
42 |
12156
4c94b6d0fb1c
tests: remove unneeded -d flags
Martin Geisler <mg@lazybytes.net>
parents:
11805
diff
changeset
|
43 changeset: 0:c19d34741b0a |
11805
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
44 user: test |
12156
4c94b6d0fb1c
tests: remove unneeded -d flags
Martin Geisler <mg@lazybytes.net>
parents:
11805
diff
changeset
|
45 date: Thu Jan 01 00:00:00 1970 +0000 |
11805
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
46 files: a |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
47 description: |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
48 1 |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
49 |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
50 |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
51 |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
52 we should see one log entry for a |
363 | 53 |
11805
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
54 $ hg log a |
12156
4c94b6d0fb1c
tests: remove unneeded -d flags
Martin Geisler <mg@lazybytes.net>
parents:
11805
diff
changeset
|
55 changeset: 0:c19d34741b0a |
11805
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
56 user: test |
12156
4c94b6d0fb1c
tests: remove unneeded -d flags
Martin Geisler <mg@lazybytes.net>
parents:
11805
diff
changeset
|
57 date: Thu Jan 01 00:00:00 1970 +0000 |
11805
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
58 summary: 1 |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
59 |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
60 |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
61 this should show a revision linked to changeset 0 |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
62 |
14182
ec5886db9dc6
tests: fix deprecated use of hg debugdata/debugindex
Sune Foldager <cryo@cyanite.org>
parents:
13962
diff
changeset
|
63 $ hg debugindex a |
37283
d4e62df1c73d
debugcommands: drop offset and length from debugindex by default
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37282
diff
changeset
|
64 rev linkrev nodeid p1 p2 |
d4e62df1c73d
debugcommands: drop offset and length from debugindex by default
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37282
diff
changeset
|
65 0 0 b789fdd96dc2 000000000000 000000000000 |
11805
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
66 |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
67 we should see one log entry for b |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
68 |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
69 $ hg log b |
12156
4c94b6d0fb1c
tests: remove unneeded -d flags
Martin Geisler <mg@lazybytes.net>
parents:
11805
diff
changeset
|
70 changeset: 1:93580a2c28a5 |
11805
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
71 tag: tip |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
72 user: test |
12156
4c94b6d0fb1c
tests: remove unneeded -d flags
Martin Geisler <mg@lazybytes.net>
parents:
11805
diff
changeset
|
73 date: Thu Jan 01 00:00:00 1970 +0000 |
11805
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
74 summary: 2 |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
75 |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
76 |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
77 this should show a revision linked to changeset 1 |
1043 | 78 |
14182
ec5886db9dc6
tests: fix deprecated use of hg debugdata/debugindex
Sune Foldager <cryo@cyanite.org>
parents:
13962
diff
changeset
|
79 $ hg debugindex b |
37283
d4e62df1c73d
debugcommands: drop offset and length from debugindex by default
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37282
diff
changeset
|
80 rev linkrev nodeid p1 p2 |
d4e62df1c73d
debugcommands: drop offset and length from debugindex by default
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37282
diff
changeset
|
81 0 1 37d9b5d994ea 000000000000 000000000000 |
11805
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
82 |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
83 this should show the rename information in the metadata |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
84 |
14182
ec5886db9dc6
tests: fix deprecated use of hg debugdata/debugindex
Sune Foldager <cryo@cyanite.org>
parents:
13962
diff
changeset
|
85 $ hg debugdata b 0 | head -3 | tail -2 |
11805
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
86 copy: a |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
87 copyrev: b789fdd96dc2f3bd229c1dd8eedf0fc60e2b68e3 |
1043 | 88 |
37338
cbc4425e81b5
tests: conditionalize tests based on presence of revlogs for files
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37330
diff
changeset
|
89 #if reporevlogstore |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
25382
diff
changeset
|
90 $ md5sum.py .hg/store/data/b.i |
26919
aa23e02f9415
test: enable generaldelta in 'test-copy.t'
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
25472
diff
changeset
|
91 44913824c8f5890ae218f9829535922e .hg/store/data/b.i |
37338
cbc4425e81b5
tests: conditionalize tests based on presence of revlogs for files
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37330
diff
changeset
|
92 #endif |
11805
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
93 $ hg cat b > bsum |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
25382
diff
changeset
|
94 $ md5sum.py bsum |
11805
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
95 60b725f10c9c85c70d97880dfe8191b3 bsum |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
96 $ hg cat a > asum |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
25382
diff
changeset
|
97 $ md5sum.py asum |
11805
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
98 60b725f10c9c85c70d97880dfe8191b3 asum |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
99 $ hg verify |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
100 checking changesets |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
101 checking manifests |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
102 crosschecking files in changesets and manifests |
8ef250726cf0
tests: unify test-copy
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
11331
diff
changeset
|
103 checking files |
39489
f1186c292d03
verify: make output less confusing (issue5924)
Meirambek Omyrzak <meirambek77@gmail.com>
parents:
39350
diff
changeset
|
104 checked 2 changesets with 2 changes to 2 files |
16856
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
105 |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
106 $ cd .. |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
107 |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
108 |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
109 $ mkdir part2 |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
110 $ cd part2 |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
111 |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
112 $ hg init |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
113 $ echo foo > foo |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
114 should fail - foo is not managed |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
115 $ hg mv foo bar |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
116 foo: not copying - file is not managed |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
117 abort: no files to copy |
47127
5ffc6c18fb96
rename: add hint about --at-rev if source file doesn't exist
Martin von Zweigbergk <martinvonz@google.com>
parents:
46886
diff
changeset
|
118 (maybe you meant to use --after --at-rev=.) |
45827
8d72e29ad1e0
errors: introduce InputError and use it from commands and cmdutil
Martin von Zweigbergk <martinvonz@google.com>
parents:
44365
diff
changeset
|
119 [10] |
16856
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
120 $ hg st -A |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
121 ? foo |
41657
e41449818bee
copy: respect ui.relative-paths in copy/rename
Martin von Zweigbergk <martinvonz@google.com>
parents:
39489
diff
changeset
|
122 respects ui.relative-paths |
e41449818bee
copy: respect ui.relative-paths in copy/rename
Martin von Zweigbergk <martinvonz@google.com>
parents:
39489
diff
changeset
|
123 $ mkdir dir |
e41449818bee
copy: respect ui.relative-paths in copy/rename
Martin von Zweigbergk <martinvonz@google.com>
parents:
39489
diff
changeset
|
124 $ cd dir |
e41449818bee
copy: respect ui.relative-paths in copy/rename
Martin von Zweigbergk <martinvonz@google.com>
parents:
39489
diff
changeset
|
125 $ hg mv ../foo ../bar |
e41449818bee
copy: respect ui.relative-paths in copy/rename
Martin von Zweigbergk <martinvonz@google.com>
parents:
39489
diff
changeset
|
126 ../foo: not copying - file is not managed |
e41449818bee
copy: respect ui.relative-paths in copy/rename
Martin von Zweigbergk <martinvonz@google.com>
parents:
39489
diff
changeset
|
127 abort: no files to copy |
47127
5ffc6c18fb96
rename: add hint about --at-rev if source file doesn't exist
Martin von Zweigbergk <martinvonz@google.com>
parents:
46886
diff
changeset
|
128 (maybe you meant to use --after --at-rev=.) |
45827
8d72e29ad1e0
errors: introduce InputError and use it from commands and cmdutil
Martin von Zweigbergk <martinvonz@google.com>
parents:
44365
diff
changeset
|
129 [10] |
41657
e41449818bee
copy: respect ui.relative-paths in copy/rename
Martin von Zweigbergk <martinvonz@google.com>
parents:
39489
diff
changeset
|
130 $ hg mv ../foo ../bar --config ui.relative-paths=yes |
e41449818bee
copy: respect ui.relative-paths in copy/rename
Martin von Zweigbergk <martinvonz@google.com>
parents:
39489
diff
changeset
|
131 ../foo: not copying - file is not managed |
e41449818bee
copy: respect ui.relative-paths in copy/rename
Martin von Zweigbergk <martinvonz@google.com>
parents:
39489
diff
changeset
|
132 abort: no files to copy |
47127
5ffc6c18fb96
rename: add hint about --at-rev if source file doesn't exist
Martin von Zweigbergk <martinvonz@google.com>
parents:
46886
diff
changeset
|
133 (maybe you meant to use --after --at-rev=.) |
45827
8d72e29ad1e0
errors: introduce InputError and use it from commands and cmdutil
Martin von Zweigbergk <martinvonz@google.com>
parents:
44365
diff
changeset
|
134 [10] |
41657
e41449818bee
copy: respect ui.relative-paths in copy/rename
Martin von Zweigbergk <martinvonz@google.com>
parents:
39489
diff
changeset
|
135 $ hg mv ../foo ../bar --config ui.relative-paths=no |
e41449818bee
copy: respect ui.relative-paths in copy/rename
Martin von Zweigbergk <martinvonz@google.com>
parents:
39489
diff
changeset
|
136 foo: not copying - file is not managed |
e41449818bee
copy: respect ui.relative-paths in copy/rename
Martin von Zweigbergk <martinvonz@google.com>
parents:
39489
diff
changeset
|
137 abort: no files to copy |
47127
5ffc6c18fb96
rename: add hint about --at-rev if source file doesn't exist
Martin von Zweigbergk <martinvonz@google.com>
parents:
46886
diff
changeset
|
138 (maybe you meant to use --after --at-rev=.) |
45827
8d72e29ad1e0
errors: introduce InputError and use it from commands and cmdutil
Martin von Zweigbergk <martinvonz@google.com>
parents:
44365
diff
changeset
|
139 [10] |
41657
e41449818bee
copy: respect ui.relative-paths in copy/rename
Martin von Zweigbergk <martinvonz@google.com>
parents:
39489
diff
changeset
|
140 $ cd .. |
e41449818bee
copy: respect ui.relative-paths in copy/rename
Martin von Zweigbergk <martinvonz@google.com>
parents:
39489
diff
changeset
|
141 $ rmdir dir |
16856
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
142 $ hg add foo |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
143 dry-run; print a warning that this is not a real copy; foo is added |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
144 $ hg mv --dry-run foo bar |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
145 foo has not been committed yet, so no copy data will be stored for bar. |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
146 $ hg st -A |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
147 A foo |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
148 should print a warning that this is not a real copy; bar is added |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
149 $ hg mv foo bar |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
150 foo has not been committed yet, so no copy data will be stored for bar. |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
151 $ hg st -A |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
152 A bar |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
153 should print a warning that this is not a real copy; foo is added |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
154 $ hg cp bar foo |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
155 bar has not been committed yet, so no copy data will be stored for foo. |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
156 $ hg rm -f bar |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
157 $ rm bar |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
158 $ hg st -A |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
159 A foo |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
160 $ hg commit -m1 |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
161 |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
162 moving a missing file |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
163 $ rm foo |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
164 $ hg mv foo foo3 |
24364
135b23868f45
commands: replace "working copy" with "working directory" in help/messages
Yuya Nishihara <yuya@tcha.org>
parents:
23958
diff
changeset
|
165 foo: deleted in working directory |
16856
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
166 foo3 does not exist! |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
167 $ hg up -qC . |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
168 |
17492 | 169 copy --after to a nonexistent target filename |
16856
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
170 $ hg cp -A foo dummy |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
171 foo: not recording copy - dummy does not exist |
39350
5b92a717bfc1
rename: return error status if any rename/copy failed
Martin von Zweigbergk <martinvonz@google.com>
parents:
39348
diff
changeset
|
172 [1] |
16856
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
173 |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
174 dry-run; should show that foo is clean |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
175 $ hg copy --dry-run foo bar |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
176 $ hg st -A |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
177 C foo |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
178 should show copy |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
179 $ hg copy foo bar |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
180 $ hg st -C |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
181 A bar |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
182 foo |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
183 |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
184 shouldn't show copy |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
185 $ hg commit -m2 |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
186 $ hg st -C |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
187 |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
188 should match |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
189 $ hg debugindex foo |
37283
d4e62df1c73d
debugcommands: drop offset and length from debugindex by default
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37282
diff
changeset
|
190 rev linkrev nodeid p1 p2 |
d4e62df1c73d
debugcommands: drop offset and length from debugindex by default
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37282
diff
changeset
|
191 0 0 2ed2a3912a0b 000000000000 000000000000 |
16856
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
192 $ hg debugrename bar |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
193 bar renamed from foo:2ed2a3912a0b24502043eae84ee4b279c18b90dd |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
194 |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
195 $ echo bleah > foo |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
196 $ echo quux > bar |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
197 $ hg commit -m3 |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
198 |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
199 should not be renamed |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
200 $ hg debugrename bar |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
201 bar not renamed |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
202 |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
203 $ hg copy -f foo bar |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
204 should show copy |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
205 $ hg st -C |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
206 M bar |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
207 foo |
23958
df463ca0adef
largefiles: revert to lfilesrepo.status() being an unfiltered method
Matt Harbison <matt_harbison@yahoo.com>
parents:
23749
diff
changeset
|
208 |
df463ca0adef
largefiles: revert to lfilesrepo.status() being an unfiltered method
Matt Harbison <matt_harbison@yahoo.com>
parents:
23749
diff
changeset
|
209 XXX: filtering lfilesrepo.status() in 3.3-rc causes the copy source to not be |
df463ca0adef
largefiles: revert to lfilesrepo.status() being an unfiltered method
Matt Harbison <matt_harbison@yahoo.com>
parents:
23749
diff
changeset
|
210 displayed. |
df463ca0adef
largefiles: revert to lfilesrepo.status() being an unfiltered method
Matt Harbison <matt_harbison@yahoo.com>
parents:
23749
diff
changeset
|
211 $ hg st -C --config extensions.largefiles= |
33425
886207fb18ab
tests: take extra care for fsmonitor at enabling incompatible extension
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents:
32267
diff
changeset
|
212 The fsmonitor extension is incompatible with the largefiles extension and has been disabled. (fsmonitor !) |
23958
df463ca0adef
largefiles: revert to lfilesrepo.status() being an unfiltered method
Matt Harbison <matt_harbison@yahoo.com>
parents:
23749
diff
changeset
|
213 M bar |
df463ca0adef
largefiles: revert to lfilesrepo.status() being an unfiltered method
Matt Harbison <matt_harbison@yahoo.com>
parents:
23749
diff
changeset
|
214 foo |
df463ca0adef
largefiles: revert to lfilesrepo.status() being an unfiltered method
Matt Harbison <matt_harbison@yahoo.com>
parents:
23749
diff
changeset
|
215 |
16856
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
216 $ hg commit -m3 |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
217 |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
218 should show no parents for tip |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
219 $ hg debugindex bar |
37283
d4e62df1c73d
debugcommands: drop offset and length from debugindex by default
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37282
diff
changeset
|
220 rev linkrev nodeid p1 p2 |
d4e62df1c73d
debugcommands: drop offset and length from debugindex by default
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37282
diff
changeset
|
221 0 1 7711d36246cc 000000000000 000000000000 |
d4e62df1c73d
debugcommands: drop offset and length from debugindex by default
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37282
diff
changeset
|
222 1 2 bdf70a2b8d03 7711d36246cc 000000000000 |
d4e62df1c73d
debugcommands: drop offset and length from debugindex by default
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37282
diff
changeset
|
223 2 3 b2558327ea8d 000000000000 000000000000 |
16856
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
224 should match |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
225 $ hg debugindex foo |
37283
d4e62df1c73d
debugcommands: drop offset and length from debugindex by default
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37282
diff
changeset
|
226 rev linkrev nodeid p1 p2 |
d4e62df1c73d
debugcommands: drop offset and length from debugindex by default
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37282
diff
changeset
|
227 0 0 2ed2a3912a0b 000000000000 000000000000 |
d4e62df1c73d
debugcommands: drop offset and length from debugindex by default
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37282
diff
changeset
|
228 1 2 dd12c926cf16 2ed2a3912a0b 000000000000 |
16856
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
229 $ hg debugrename bar |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
230 bar renamed from foo:dd12c926cf165e3eb4cf87b084955cb617221c17 |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
231 |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
232 should show no copies |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
233 $ hg st -C |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
234 |
46408
e948ad0dcbe2
copies: add an devel option to trace all files
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
45844
diff
changeset
|
235 note: since filelog based copy tracing only trace copy for new file, the copy information here is not displayed. |
e948ad0dcbe2
copies: add an devel option to trace all files
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
45844
diff
changeset
|
236 |
e948ad0dcbe2
copies: add an devel option to trace all files
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
45844
diff
changeset
|
237 $ hg status --copies --change . |
e948ad0dcbe2
copies: add an devel option to trace all files
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
45844
diff
changeset
|
238 M bar |
e948ad0dcbe2
copies: add an devel option to trace all files
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
45844
diff
changeset
|
239 |
e948ad0dcbe2
copies: add an devel option to trace all files
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
45844
diff
changeset
|
240 They are a devel option to walk all file and fine this information anyway. |
e948ad0dcbe2
copies: add an devel option to trace all files
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
45844
diff
changeset
|
241 |
e948ad0dcbe2
copies: add an devel option to trace all files
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
45844
diff
changeset
|
242 $ hg status --copies --change . --config devel.copy-tracing.trace-all-files=yes |
e948ad0dcbe2
copies: add an devel option to trace all files
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
45844
diff
changeset
|
243 M bar |
e948ad0dcbe2
copies: add an devel option to trace all files
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
45844
diff
changeset
|
244 foo |
e948ad0dcbe2
copies: add an devel option to trace all files
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
45844
diff
changeset
|
245 |
16856
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
246 copy --after on an added file |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
247 $ cp bar baz |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
248 $ hg add baz |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
249 $ hg cp -A bar baz |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
250 $ hg st -C |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
251 A baz |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
252 bar |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
253 |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
254 foo was clean: |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
255 $ hg st -AC foo |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
256 C foo |
29958
37a36c05dcc3
copy: document current behavior of 'hg cp --after'
Augie Fackler <augie@google.com>
parents:
26919
diff
changeset
|
257 Trying to copy on top of an existing file fails, |
37a36c05dcc3
copy: document current behavior of 'hg cp --after'
Augie Fackler <augie@google.com>
parents:
26919
diff
changeset
|
258 $ hg copy -A bar foo |
30151
381293e1135e
copy: distinguish "file exists" cases and add a hint (BC)
Augie Fackler <augie@google.com>
parents:
29958
diff
changeset
|
259 foo: not overwriting - file already committed |
39348
cde75233c415
rename: quote hg commands in warnings
Martin von Zweigbergk <martinvonz@google.com>
parents:
37338
diff
changeset
|
260 ('hg copy --after --force' to replace the file by recording a copy) |
39350
5b92a717bfc1
rename: return error status if any rename/copy failed
Martin von Zweigbergk <martinvonz@google.com>
parents:
39348
diff
changeset
|
261 [1] |
30151
381293e1135e
copy: distinguish "file exists" cases and add a hint (BC)
Augie Fackler <augie@google.com>
parents:
29958
diff
changeset
|
262 same error without the --after, so the user doesn't have to go through |
381293e1135e
copy: distinguish "file exists" cases and add a hint (BC)
Augie Fackler <augie@google.com>
parents:
29958
diff
changeset
|
263 two hints: |
381293e1135e
copy: distinguish "file exists" cases and add a hint (BC)
Augie Fackler <augie@google.com>
parents:
29958
diff
changeset
|
264 $ hg copy bar foo |
381293e1135e
copy: distinguish "file exists" cases and add a hint (BC)
Augie Fackler <augie@google.com>
parents:
29958
diff
changeset
|
265 foo: not overwriting - file already committed |
39348
cde75233c415
rename: quote hg commands in warnings
Martin von Zweigbergk <martinvonz@google.com>
parents:
37338
diff
changeset
|
266 ('hg copy --force' to replace the file by recording a copy) |
39350
5b92a717bfc1
rename: return error status if any rename/copy failed
Martin von Zweigbergk <martinvonz@google.com>
parents:
39348
diff
changeset
|
267 [1] |
16856
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
268 but it's considered modified after a copy --after --force |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
269 $ hg copy -Af bar foo |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
270 $ hg st -AC foo |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
271 M foo |
241a32942c7a
tests: roll test-copy2.t into test-copy.t
Adrian Buehlmann <adrian@cadifra.com>
parents:
16350
diff
changeset
|
272 bar |
30151
381293e1135e
copy: distinguish "file exists" cases and add a hint (BC)
Augie Fackler <augie@google.com>
parents:
29958
diff
changeset
|
273 The hint for a file that exists but is not in file history doesn't |
381293e1135e
copy: distinguish "file exists" cases and add a hint (BC)
Augie Fackler <augie@google.com>
parents:
29958
diff
changeset
|
274 mention --force: |
381293e1135e
copy: distinguish "file exists" cases and add a hint (BC)
Augie Fackler <augie@google.com>
parents:
29958
diff
changeset
|
275 $ touch xyzzy |
381293e1135e
copy: distinguish "file exists" cases and add a hint (BC)
Augie Fackler <augie@google.com>
parents:
29958
diff
changeset
|
276 $ hg cp bar xyzzy |
381293e1135e
copy: distinguish "file exists" cases and add a hint (BC)
Augie Fackler <augie@google.com>
parents:
29958
diff
changeset
|
277 xyzzy: not overwriting - file exists |
39348
cde75233c415
rename: quote hg commands in warnings
Martin von Zweigbergk <martinvonz@google.com>
parents:
37338
diff
changeset
|
278 ('hg copy --after' to record the copy) |
39350
5b92a717bfc1
rename: return error status if any rename/copy failed
Martin von Zweigbergk <martinvonz@google.com>
parents:
39348
diff
changeset
|
279 [1] |
44364
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
280 $ hg co -qC . |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
281 $ rm baz xyzzy |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
282 |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
283 |
46886
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
284 Test unmarking copy/rename of a single file |
44364
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
285 |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
286 # Set up by creating a copy |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
287 $ hg cp bar baz |
46886
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
288 # Test unmarking as copy a non-existent file |
44364
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
289 $ hg copy --forget non-existent |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
290 non-existent: $ENOENT$ |
46886
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
291 $ hg rename --forget non-existent |
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
292 non-existent: $ENOENT$ |
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
293 # Test unmarking as copy an tracked but unrelated file |
44364
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
294 $ hg copy --forget foo |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
295 foo: not unmarking as copy - file is not marked as copied |
46886
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
296 $ hg rename --forget foo |
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
297 foo: not unmarking as copy - file is not marked as copied |
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
298 # Test unmarking as copy a copy source |
44364
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
299 $ hg copy --forget bar |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
300 bar: not unmarking as copy - file is not marked as copied |
46886
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
301 $ hg rename --forget bar |
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
302 bar: not unmarking as copy - file is not marked as copied |
44364
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
303 # baz should still be marked as a copy |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
304 $ hg st -C |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
305 A baz |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
306 bar |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
307 # Test the normal case |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
308 $ hg copy --forget baz |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
309 $ hg st -C |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
310 A baz |
46886
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
311 $ rm bar |
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
312 $ hg rename --after bar baz |
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
313 $ hg st -C |
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
314 A baz |
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
315 bar |
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
316 R bar |
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
317 $ hg rename --forget baz |
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
318 $ hg st -C |
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
319 A baz |
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
320 R bar |
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
321 $ hg revert bar |
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
322 # Test unmarking as copy with matching an non-matching patterns |
44364
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
323 $ hg cp bar baz --after |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
324 $ hg copy --forget bar baz |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
325 bar: not unmarking as copy - file is not marked as copied |
46886
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
326 $ hg cp bar baz --after |
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
327 $ hg rename --forget bar baz |
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
328 bar: not unmarking as copy - file is not marked as copied |
44364
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
329 $ hg st -C |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
330 A baz |
46886
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
331 # Test unmarking as copy with no exact matches |
44364
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
332 $ hg cp bar baz --after |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
333 $ hg copy --forget . |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
334 $ hg st -C |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
335 A baz |
46886
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
336 $ hg cp bar baz --after |
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
337 $ hg st -C |
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
338 A baz |
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
339 bar |
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
340 $ hg rename --forget . |
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
341 $ hg st -C |
37f49d462394
rename: add --forget option and stop suggesting `hg revert` for undoing
Martin von Zweigbergk <martinvonz@google.com>
parents:
46408
diff
changeset
|
342 A baz |
44364
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
343 $ hg forget baz |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
344 $ rm baz |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
345 |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
346 Test unmarking copy of a directory |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
347 |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
348 $ mkdir dir |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
349 $ echo foo > dir/foo |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
350 $ echo bar > dir/bar |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
351 $ hg add dir |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
352 adding dir/bar |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
353 adding dir/foo |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
354 $ hg ci -m 'add dir/' |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
355 $ hg cp dir dir2 |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
356 copying dir/bar to dir2/bar |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
357 copying dir/foo to dir2/foo |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
358 $ touch dir2/untracked |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
359 $ hg copy --forget dir2 |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
360 $ hg st -C |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
361 A dir2/bar |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
362 A dir2/foo |
8be0c63535b5
copy: add option to unmark file as copied
Martin von Zweigbergk <martinvonz@google.com>
parents:
41657
diff
changeset
|
363 ? dir2/untracked |
44365
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
364 # Clean up for next test |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
365 $ hg forget dir2 |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
366 removing dir2/bar |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
367 removing dir2/foo |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
368 $ rm -r dir2 |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
369 |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
370 Test uncopy on committed copies |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
371 |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
372 # Commit some copies |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
373 $ hg cp bar baz |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
374 $ hg cp bar qux |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
375 $ hg ci -m copies |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
376 $ hg st -C --change . |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
377 A baz |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
378 bar |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
379 A qux |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
380 bar |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
381 $ base=$(hg log -r '.^' -T '{rev}') |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
382 $ hg log -G -T '{rev}:{node|short} {desc}\n' -r $base: |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
383 @ 5:a612dc2edfda copies |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
384 | |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
385 o 4:4800b1f1f38e add dir/ |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
386 | |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
387 ~ |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
388 # Add a dirty change on top to show that it's unaffected |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
389 $ echo dirty >> baz |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
390 $ hg st |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
391 M baz |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
392 $ cat baz |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
393 bleah |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
394 dirty |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
395 $ hg copy --forget --at-rev . baz |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
396 saved backup bundle to $TESTTMP/part2/.hg/strip-backup/a612dc2edfda-e36b4448-uncopy.hg |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
397 # The unwanted copy is no longer recorded, but the unrelated one is |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
398 $ hg st -C --change . |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
399 A baz |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
400 A qux |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
401 bar |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
402 # The old commit is gone and we have updated to the new commit |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
403 $ hg log -G -T '{rev}:{node|short} {desc}\n' -r $base: |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
404 @ 5:c45090e5effe copies |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
405 | |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
406 o 4:4800b1f1f38e add dir/ |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
407 | |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
408 ~ |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
409 # Working copy still has the uncommitted change |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
410 $ hg st |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
411 M baz |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
412 $ cat baz |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
413 bleah |
7c4b98a4e536
copy: add experimetal support for unmarking committed copies
Martin von Zweigbergk <martinvonz@google.com>
parents:
44364
diff
changeset
|
414 dirty |
16913
f2719b387380
tests: add missing trailing 'cd ..'
Mads Kiilerich <mads@kiilerich.com>
parents:
16856
diff
changeset
|
415 |
f2719b387380
tests: add missing trailing 'cd ..'
Mads Kiilerich <mads@kiilerich.com>
parents:
16856
diff
changeset
|
416 $ cd .. |