Show More
@@ -1,7 +1,10 b'' | |||
|
1 | 1 | #!/bin/sh |
|
2 | 2 | |
|
3 | 3 | hg init a |
|
4 | mkdir a/d1 | |
|
5 | mkdir a/d1/d2 | |
|
4 | 6 | echo line 1 > a/a |
|
7 | echo line 1 > a/d1/d2/a | |
|
5 | 8 | hg --cwd a ci -d '0 0' -Ama |
|
6 | 9 | |
|
7 | 10 | echo line 2 >> a/a |
@@ -79,3 +82,19 b' python mkmsg.py | hg --cwd b import -' | |||
|
79 | 82 | hg --cwd b tip | grep second |
|
80 | 83 | rm -rf b |
|
81 | 84 | |
|
85 | # bug non regression test | |
|
86 | # importing a patch in a subdirectory failed at the commit stage | |
|
87 | echo line 2 >> a/d1/d2/a | |
|
88 | hg --cwd a ci -u someoneelse -d '1 0' -m'subdir change' | |
|
89 | echo % hg import in a subdirectory | |
|
90 | hg clone -r0 a b | |
|
91 | hg --cwd a export tip | sed -e 's/d1\/d2\///' > tip.patch | |
|
92 | pushd b/d1/d2 2>&1 > /dev/null | |
|
93 | hg import ../../../tip.patch | |
|
94 | popd 2>&1 > /dev/null | |
|
95 | echo "% message should be 'subdir change'" | |
|
96 | hg --cwd b tip | grep 'subdir change' | |
|
97 | echo "% committer should be 'someoneelse'" | |
|
98 | hg --cwd b tip | grep someoneelse | |
|
99 | echo "% should be empty" | |
|
100 | hg --cwd b status |
@@ -1,11 +1,12 b'' | |||
|
1 | 1 | adding a |
|
2 | adding d1/d2/a | |
|
2 | 3 | % import exported patch |
|
3 | 4 | requesting all changes |
|
4 | 5 | adding changesets |
|
5 | 6 | adding manifests |
|
6 | 7 | adding file changes |
|
7 |
added 1 changesets with |
|
|
8 |
|
|
|
8 | added 1 changesets with 2 changes to 2 files | |
|
9 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
|
9 | 10 | applying ../tip.patch |
|
10 | 11 | patching file a |
|
11 | 12 | % message should be same |
@@ -17,8 +18,8 b' requesting all changes' | |||
|
17 | 18 | adding changesets |
|
18 | 19 | adding manifests |
|
19 | 20 | adding file changes |
|
20 |
added 1 changesets with |
|
|
21 |
|
|
|
21 | added 1 changesets with 2 changes to 2 files | |
|
22 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
|
22 | 23 | applying ../tip.patch |
|
23 | 24 | patching file a |
|
24 | 25 | transaction abort! |
@@ -28,8 +29,8 b' requesting all changes' | |||
|
28 | 29 | adding changesets |
|
29 | 30 | adding manifests |
|
30 | 31 | adding file changes |
|
31 |
added 1 changesets with |
|
|
32 |
|
|
|
32 | added 1 changesets with 2 changes to 2 files | |
|
33 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
|
33 | 34 | applying ../tip.patch |
|
34 | 35 | patching file a |
|
35 | 36 | % import from stdin |
@@ -37,8 +38,8 b' requesting all changes' | |||
|
37 | 38 | adding changesets |
|
38 | 39 | adding manifests |
|
39 | 40 | adding file changes |
|
40 |
added 1 changesets with |
|
|
41 |
|
|
|
41 | added 1 changesets with 2 changes to 2 files | |
|
42 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
|
42 | 43 | applying patch from stdin |
|
43 | 44 | patching file a |
|
44 | 45 | % override commit message |
@@ -46,8 +47,8 b' requesting all changes' | |||
|
46 | 47 | adding changesets |
|
47 | 48 | adding manifests |
|
48 | 49 | adding file changes |
|
49 |
added 1 changesets with |
|
|
50 |
|
|
|
50 | added 1 changesets with 2 changes to 2 files | |
|
51 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
|
51 | 52 | applying patch from stdin |
|
52 | 53 | patching file a |
|
53 | 54 | summary: override |
@@ -56,8 +57,8 b' requesting all changes' | |||
|
56 | 57 | adding changesets |
|
57 | 58 | adding manifests |
|
58 | 59 | adding file changes |
|
59 |
added 1 changesets with |
|
|
60 |
|
|
|
60 | added 1 changesets with 2 changes to 2 files | |
|
61 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
|
61 | 62 | applying ../msg.patch |
|
62 | 63 | patching file a |
|
63 | 64 | user: email patcher |
@@ -67,8 +68,8 b' requesting all changes' | |||
|
67 | 68 | adding changesets |
|
68 | 69 | adding manifests |
|
69 | 70 | adding file changes |
|
70 |
added 1 changesets with |
|
|
71 |
|
|
|
71 | added 1 changesets with 2 changes to 2 files | |
|
72 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
|
72 | 73 | applying patch from stdin |
|
73 | 74 | patching file a |
|
74 | 75 | % plain diff in email, subject, no message body |
@@ -76,8 +77,8 b' requesting all changes' | |||
|
76 | 77 | adding changesets |
|
77 | 78 | adding manifests |
|
78 | 79 | adding file changes |
|
79 |
added 1 changesets with |
|
|
80 |
|
|
|
80 | added 1 changesets with 2 changes to 2 files | |
|
81 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
|
81 | 82 | applying patch from stdin |
|
82 | 83 | patching file a |
|
83 | 84 | % plain diff in email, no subject, no message body, should fail |
@@ -85,8 +86,8 b' requesting all changes' | |||
|
85 | 86 | adding changesets |
|
86 | 87 | adding manifests |
|
87 | 88 | adding file changes |
|
88 |
added 1 changesets with |
|
|
89 |
|
|
|
89 | added 1 changesets with 2 changes to 2 files | |
|
90 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
|
90 | 91 | applying patch from stdin |
|
91 | 92 | patching file a |
|
92 | 93 | transaction abort! |
@@ -96,8 +97,22 b' requesting all changes' | |||
|
96 | 97 | adding changesets |
|
97 | 98 | adding manifests |
|
98 | 99 | adding file changes |
|
99 |
added 1 changesets with |
|
|
100 |
|
|
|
100 | added 1 changesets with 2 changes to 2 files | |
|
101 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
|
101 | 102 | applying patch from stdin |
|
102 | 103 | patching file a |
|
103 | 104 | summary: second change |
|
105 | % hg import in a subdirectory | |
|
106 | requesting all changes | |
|
107 | adding changesets | |
|
108 | adding manifests | |
|
109 | adding file changes | |
|
110 | added 1 changesets with 2 changes to 2 files | |
|
111 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
|
112 | applying ../../../tip.patch | |
|
113 | patching file a | |
|
114 | % message should be 'subdir change' | |
|
115 | summary: subdir change | |
|
116 | % committer should be 'someoneelse' | |
|
117 | user: someoneelse | |
|
118 | % should be empty |
General Comments 0
You need to be logged in to leave comments.
Login now