Show More
@@ -1,5 +1,3 b'' | |||||
1 | $ "$TESTDIR/hghave" symlink execbit || exit 80 |
|
|||
2 |
|
||||
3 |
|
|
1 | $ . "$TESTDIR/bzr-definitions" | |
4 |
|
2 | |||
5 | create and rename on the same file in the same step |
|
3 | create and rename on the same file in the same step | |
@@ -157,6 +155,8 b' merge' | |||||
157 |
|
155 | |||
158 | $ cd .. |
|
156 | $ cd .. | |
159 |
|
157 | |||
|
158 | #if symlink execbit | |||
|
159 | ||||
160 | symlinks and executable files |
|
160 | symlinks and executable files | |
161 |
|
161 | |||
162 | $ mkdir test-symlinks |
|
162 | $ mkdir test-symlinks | |
@@ -199,14 +199,17 b' symlinks and executable files' | |||||
199 | 755 * newprog |
|
199 | 755 * newprog | |
200 | 644 program |
|
200 | 644 program | |
201 | 644 @ syma |
|
201 | 644 @ syma | |
202 | $ cd source-hg |
|
|||
203 |
|
202 | |||
204 | test the symlinks can be recreated |
|
203 | test the symlinks can be recreated | |
205 |
|
204 | |||
|
205 | $ cd source-hg | |||
206 | $ hg up |
|
206 | $ hg up | |
207 | 5 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
207 | 5 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
208 | $ hg cat syma; echo |
|
208 | $ hg cat syma; echo | |
209 | a |
|
209 | a | |
|
210 | $ cd ../.. | |||
|
211 | ||||
|
212 | #endif | |||
210 |
|
213 | |||
211 | Multiple branches |
|
214 | Multiple branches | |
212 |
|
215 |
@@ -1,5 +1,3 b'' | |||||
1 | $ "$TESTDIR/hghave" execbit || exit 80 |
|
|||
2 |
|
||||
3 |
|
|
1 | $ cat >> $HGRCPATH <<EOF | |
4 | > [extensions] |
|
2 | > [extensions] | |
5 | > convert= |
|
3 | > convert= | |
@@ -33,7 +31,11 b'' | |||||
33 | (branch merge, don't forget to commit) |
|
31 | (branch merge, don't forget to commit) | |
34 | $ hg ci -m 'merge remote copy' -d '4 0' |
|
32 | $ hg ci -m 'merge remote copy' -d '4 0' | |
35 | created new head |
|
33 | created new head | |
|
34 | #if execbit | |||
36 | $ chmod +x baz |
|
35 | $ chmod +x baz | |
|
36 | #else | |||
|
37 | $ echo some other change to make sure we get a rev 5 > baz | |||
|
38 | #endif | |||
37 | $ hg ci -m 'mark baz executable' -d '5 0' |
|
39 | $ hg ci -m 'mark baz executable' -d '5 0' | |
38 | $ cd .. |
|
40 | $ cd .. | |
39 | $ hg convert --datesort orig new 2>&1 | grep -v 'subversion python bindings could not be loaded' |
|
41 | $ hg convert --datesort orig new 2>&1 | grep -v 'subversion python bindings could not be loaded' | |
@@ -54,9 +56,16 b'' | |||||
54 | searching for changes |
|
56 | searching for changes | |
55 | no changes found |
|
57 | no changes found | |
56 | [1] |
|
58 | [1] | |
|
59 | #if execbit | |||
57 | $ hg bookmarks |
|
60 | $ hg bookmarks | |
58 | premerge1 3:973ef48a98a4 |
|
61 | premerge1 3:973ef48a98a4 | |
59 | premerge2 5:13d9b87cf8f8 |
|
62 | premerge2 5:13d9b87cf8f8 | |
|
63 | #else | |||
|
64 | Different hash because no x bit | |||
|
65 | $ hg bookmarks | |||
|
66 | premerge1 3:973ef48a98a4 | |||
|
67 | premerge2 5:df0779bcf33c | |||
|
68 | #endif | |||
60 | $ cd .. |
|
69 | $ cd .. | |
61 |
|
70 | |||
62 | check shamap LF and CRLF handling |
|
71 | check shamap LF and CRLF handling |
@@ -1,4 +1,4 b'' | |||||
1 |
$ "$TESTDIR/hghave" svn13 no-outer-repo symlink |
|
1 | $ "$TESTDIR/hghave" svn13 no-outer-repo symlink || exit 80 | |
2 |
|
2 | |||
3 | $ fixpath() |
|
3 | $ fixpath() | |
4 | > { |
|
4 | > { | |
@@ -202,12 +202,21 b' Remove' | |||||
202 | d1 |
|
202 | d1 | |
203 | newlink |
|
203 | newlink | |
204 |
|
204 | |||
205 |
Exec |
|
205 | Executable | |
206 |
|
206 | |||
|
207 | #if execbit | |||
207 | $ chmod +x a/c |
|
208 | $ chmod +x a/c | |
|
209 | #else | |||
|
210 | $ echo fake >> a/c | |||
|
211 | #endif | |||
208 | $ hg --cwd a ci -d '5 0' -m 'make a file executable' |
|
212 | $ hg --cwd a ci -d '5 0' -m 'make a file executable' | |
|
213 | #if execbit | |||
209 | $ hg --cwd a tip -q |
|
214 | $ hg --cwd a tip -q | |
210 | 5:31093672760b |
|
215 | 5:31093672760b | |
|
216 | #else | |||
|
217 | $ hg --cwd a tip -q | |||
|
218 | 5:034971d37224 | |||
|
219 | #endif | |||
211 |
|
220 | |||
212 | $ hg convert -d svn a |
|
221 | $ hg convert -d svn a | |
213 | assuming destination a-hg |
|
222 | assuming destination a-hg | |
@@ -227,16 +236,22 b' Exectutable' | |||||
227 | author: test |
|
236 | author: test | |
228 | msg: make a file executable |
|
237 | msg: make a file executable | |
229 | M /c |
|
238 | M /c | |
|
239 | #if execbit | |||
230 | $ test -x a-hg-wc/c |
|
240 | $ test -x a-hg-wc/c | |
|
241 | #endif | |||
|
242 | $ rm -rf a a-hg a-hg-wc | |||
231 |
|
243 | |||
232 | Executable in new directory |
|
244 | Executable in new directory | |
233 |
|
245 | |||
234 | $ rm -rf a a-hg a-hg-wc |
|
|||
235 | $ hg init a |
|
246 | $ hg init a | |
236 |
|
247 | |||
237 | $ mkdir a/d1 |
|
248 | $ mkdir a/d1 | |
238 | $ echo a > a/d1/a |
|
249 | $ echo a > a/d1/a | |
|
250 | #if execbit | |||
239 | $ chmod +x a/d1/a |
|
251 | $ chmod +x a/d1/a | |
|
252 | #else | |||
|
253 | $ echo fake >> a/d1/a | |||
|
254 | #endif | |||
240 | $ hg --cwd a ci -d '0 0' -A -m 'add executable file in new directory' |
|
255 | $ hg --cwd a ci -d '0 0' -A -m 'add executable file in new directory' | |
241 | adding d1/a |
|
256 | adding d1/a | |
242 |
|
257 | |||
@@ -257,7 +272,9 b' Executable in new directory' | |||||
257 | msg: add executable file in new directory |
|
272 | msg: add executable file in new directory | |
258 | A /d1 |
|
273 | A /d1 | |
259 | A /d1/a |
|
274 | A /d1/a | |
|
275 | #if execbit | |||
260 | $ test -x a-hg-wc/d1/a |
|
276 | $ test -x a-hg-wc/d1/a | |
|
277 | #endif | |||
261 |
|
278 | |||
262 | Copy to new directory |
|
279 | Copy to new directory | |
263 |
|
280 |
@@ -1,5 +1,3 b'' | |||||
1 | $ "$TESTDIR/hghave" execbit || exit 80 |
|
|||
2 |
|
||||
3 | Setup |
|
1 | Setup | |
4 |
|
2 | |||
5 | $ echo "[color]" >> $HGRCPATH |
|
3 | $ echo "[color]" >> $HGRCPATH | |
@@ -74,6 +72,8 b' diffstat' | |||||
74 | $ echo "[diff]" >> $HGRCPATH |
|
72 | $ echo "[diff]" >> $HGRCPATH | |
75 | $ echo "git=True" >> $HGRCPATH |
|
73 | $ echo "git=True" >> $HGRCPATH | |
76 |
|
74 | |||
|
75 | #if execbit | |||
|
76 | ||||
77 | record |
|
77 | record | |
78 |
|
78 | |||
79 | $ chmod +x a |
|
79 | $ chmod +x a | |
@@ -124,3 +124,5 b' qrecord' | |||||
124 | a |
|
124 | a | |
125 | c |
|
125 | c | |
126 | \x1b[0;33mrecord this change to 'a'? [Ynesfdaq?]\x1b[0m (esc) |
|
126 | \x1b[0;33mrecord this change to 'a'? [Ynesfdaq?]\x1b[0m (esc) | |
|
127 | ||||
|
128 | #endif |
@@ -1,5 +1,3 b'' | |||||
1 | $ "$TESTDIR/hghave" symlink execbit || exit 80 |
|
|||
2 |
|
||||
3 |
|
|
1 | $ echo "[extensions]" >> $HGRCPATH | |
4 | $ echo "extdiff=" >> $HGRCPATH |
|
2 | $ echo "extdiff=" >> $HGRCPATH | |
5 |
|
3 | |||
@@ -94,6 +92,8 b' Check diff are made from the first paren' | |||||
94 | diffing */extdiff.*/a.2a13a4d2da36/a a.46c0e4daeb72/a (glob) |
|
92 | diffing */extdiff.*/a.2a13a4d2da36/a a.46c0e4daeb72/a (glob) | |
95 | diff-like tools yield a non-zero exit code |
|
93 | diff-like tools yield a non-zero exit code | |
96 |
|
94 | |||
|
95 | #if execbit | |||
|
96 | ||||
97 | Test extdiff of multiple files in tmp dir: |
|
97 | Test extdiff of multiple files in tmp dir: | |
98 |
|
98 | |||
99 | $ hg update -C 0 > /dev/null |
|
99 | $ hg update -C 0 > /dev/null | |
@@ -182,6 +182,10 b' Test with revsets:' | |||||
182 |
|
182 | |||
183 | $ cd .. |
|
183 | $ cd .. | |
184 |
|
184 | |||
|
185 | #endif | |||
|
186 | ||||
|
187 | #if symlink | |||
|
188 | ||||
185 | Test symlinks handling (issue1909) |
|
189 | Test symlinks handling (issue1909) | |
186 |
|
190 | |||
187 | $ hg init testsymlinks |
|
191 | $ hg init testsymlinks | |
@@ -196,3 +200,5 b' Test symlinks handling (issue1909)' | |||||
196 | diffing testsymlinks.07f494440405 testsymlinks |
|
200 | diffing testsymlinks.07f494440405 testsymlinks | |
197 | [1] |
|
201 | [1] | |
198 | $ cd .. |
|
202 | $ cd .. | |
|
203 | ||||
|
204 | #endif |
@@ -1,5 +1,3 b'' | |||||
1 | $ "$TESTDIR/hghave" execbit || exit 80 |
|
|||
2 |
|
||||
3 |
|
|
1 | $ hg init | |
4 | $ echo start > start |
|
2 | $ echo start > start | |
5 | $ hg ci -Amstart |
|
3 | $ hg ci -Amstart | |
@@ -58,6 +56,8 b' Delete:' | |||||
58 | $ hg ci -Amsrc |
|
56 | $ hg ci -Amsrc | |
59 | adding src |
|
57 | adding src | |
60 |
|
58 | |||
|
59 | #if execbit | |||
|
60 | ||||
61 | chmod 644: |
|
61 | chmod 644: | |
62 |
|
62 | |||
63 | $ chmod +x src |
|
63 | $ chmod +x src | |
@@ -94,6 +94,17 b' Nonexistent in tip+chmod:' | |||||
94 | old mode 100644 |
|
94 | old mode 100644 | |
95 | new mode 100755 |
|
95 | new mode 100755 | |
96 |
|
96 | |||
|
97 | #else | |||
|
98 | ||||
|
99 | Dummy changes when no exec bit, mocking the execbit commit structure | |||
|
100 | ||||
|
101 | $ echo change >> src | |||
|
102 | $ hg ci -munexec | |||
|
103 | $ hg mv src dst | |||
|
104 | $ hg ci -mrenamemod | |||
|
105 | ||||
|
106 | #endif | |||
|
107 | ||||
97 | Binary diff: |
|
108 | Binary diff: | |
98 |
|
109 | |||
99 | $ cp "$TESTDIR/binfile.bin" . |
|
110 | $ cp "$TESTDIR/binfile.bin" . |
@@ -1,5 +1,3 b'' | |||||
1 | $ "$TESTDIR/hghave" symlink execbit || exit 80 |
|
|||
2 |
|
||||
3 |
|
|
1 | $ echo "[extensions]" >> $HGRCPATH | |
4 | $ echo "purge=" >> $HGRCPATH |
|
2 | $ echo "purge=" >> $HGRCPATH | |
5 | $ echo "graphlog=" >> $HGRCPATH |
|
3 | $ echo "graphlog=" >> $HGRCPATH | |
@@ -218,6 +216,8 b' Test applying multiple patches with --ex' | |||||
218 |
|
216 | |||
219 | $ cd .. |
|
217 | $ cd .. | |
220 |
|
218 | |||
|
219 | #if symlink execbit | |||
|
220 | ||||
221 | Test complicated patch with --exact |
|
221 | Test complicated patch with --exact | |
222 |
|
222 | |||
223 | $ hg init repo-exact |
|
223 | $ hg init repo-exact | |
@@ -265,3 +265,4 b' data. If not, diff both heads to debug i' | |||||
265 | | |
|
265 | | | |
266 | o 0:a0e19e636a43 test 0 0 - default - t |
|
266 | o 0:a0e19e636a43 test 0 0 - default - t | |
267 |
|
267 | |||
|
268 | #endif |
@@ -1,5 +1,3 b'' | |||||
1 | $ "$TESTDIR/hghave" execbit || exit 80 |
|
|||
2 |
|
||||
3 |
|
|
1 | $ checkundo() | |
4 | > { |
|
2 | > { | |
5 | > if [ -f .hg/store/undo ]; then |
|
3 | > if [ -f .hg/store/undo ]; then | |
@@ -918,9 +916,12 b' bad node in status' | |||||
918 |
|
916 | |||
919 | $ hg qnew -m'new file' new |
|
917 | $ hg qnew -m'new file' new | |
920 | $ echo foo > new |
|
918 | $ echo foo > new | |
|
919 | #if execbit | |||
921 | $ chmod +x new |
|
920 | $ chmod +x new | |
|
921 | #endif | |||
922 | $ hg add new |
|
922 | $ hg add new | |
923 | $ hg qrefresh |
|
923 | $ hg qrefresh | |
|
924 | #if execbit | |||
924 | $ cat .hg/patches/new |
|
925 | $ cat .hg/patches/new | |
925 | new file |
|
926 | new file | |
926 |
|
927 | |||
@@ -930,6 +931,17 b' bad node in status' | |||||
930 | +++ b/new |
|
931 | +++ b/new | |
931 | @@ -0,0 +1,1 @@ |
|
932 | @@ -0,0 +1,1 @@ | |
932 | +foo |
|
933 | +foo | |
|
934 | #else | |||
|
935 | $ cat .hg/patches/new | |||
|
936 | new file | |||
|
937 | ||||
|
938 | diff --git a/new b/new | |||
|
939 | new file mode 100644 | |||
|
940 | --- /dev/null | |||
|
941 | +++ b/new | |||
|
942 | @@ -0,0 +1,1 @@ | |||
|
943 | +foo | |||
|
944 | #endif | |||
933 |
|
945 | |||
934 | $ hg qnew -m'copy file' copy |
|
946 | $ hg qnew -m'copy file' copy | |
935 | $ hg cp new copy |
|
947 | $ hg cp new copy |
@@ -772,6 +772,8 b' f' | |||||
772 | +a |
|
772 | +a | |
773 |
|
773 | |||
774 |
|
774 | |||
|
775 | #if execbit | |||
|
776 | ||||
775 | Preserve chmod +x |
|
777 | Preserve chmod +x | |
776 |
|
778 | |||
777 | $ chmod +x f1 |
|
779 | $ chmod +x f1 | |
@@ -885,8 +887,120 b' Preserve chmod -x' | |||||
885 | +c |
|
887 | +c | |
886 |
|
888 | |||
887 |
|
889 | |||
|
890 | #else | |||
|
891 | ||||
|
892 | Slightly bogus tests to get almost same repo structure as when x bit is used | |||
|
893 | - but with different hashes. | |||
|
894 | ||||
|
895 | Mock "Preserve chmod +x" | |||
|
896 | ||||
|
897 | $ echo a >> f1 | |||
|
898 | $ hg record -d '20 0' -mz <<EOF | |||
|
899 | > y | |||
|
900 | > y | |||
|
901 | > y | |||
|
902 | > EOF | |||
|
903 | diff --git a/subdir/f1 b/subdir/f1 | |||
|
904 | 1 hunks, 1 lines changed | |||
|
905 | examine changes to 'subdir/f1'? [Ynesfdaq?] | |||
|
906 | @@ -1,2 +1,3 @@ | |||
|
907 | a | |||
|
908 | a | |||
|
909 | +a | |||
|
910 | record this change to 'subdir/f1'? [Ynesfdaq?] | |||
|
911 | ||||
|
912 | $ hg tip --config diff.git=True -p | |||
|
913 | changeset: 22:0d463bd428f5 | |||
|
914 | tag: tip | |||
|
915 | user: test | |||
|
916 | date: Thu Jan 01 00:00:20 1970 +0000 | |||
|
917 | summary: z | |||
|
918 | ||||
|
919 | diff --git a/subdir/f1 b/subdir/f1 | |||
|
920 | --- a/subdir/f1 | |||
|
921 | +++ b/subdir/f1 | |||
|
922 | @@ -1,2 +1,3 @@ | |||
|
923 | a | |||
|
924 | a | |||
|
925 | +a | |||
|
926 | ||||
|
927 | ||||
|
928 | Mock "Preserve execute permission on original" | |||
|
929 | ||||
|
930 | $ echo b >> f1 | |||
|
931 | $ hg record -d '21 0' -maa <<EOF | |||
|
932 | > y | |||
|
933 | > y | |||
|
934 | > y | |||
|
935 | > EOF | |||
|
936 | diff --git a/subdir/f1 b/subdir/f1 | |||
|
937 | 1 hunks, 1 lines changed | |||
|
938 | examine changes to 'subdir/f1'? [Ynesfdaq?] | |||
|
939 | @@ -1,3 +1,4 @@ | |||
|
940 | a | |||
|
941 | a | |||
|
942 | a | |||
|
943 | +b | |||
|
944 | record this change to 'subdir/f1'? [Ynesfdaq?] | |||
|
945 | ||||
|
946 | $ hg tip --config diff.git=True -p | |||
|
947 | changeset: 23:0eab41a3e524 | |||
|
948 | tag: tip | |||
|
949 | user: test | |||
|
950 | date: Thu Jan 01 00:00:21 1970 +0000 | |||
|
951 | summary: aa | |||
|
952 | ||||
|
953 | diff --git a/subdir/f1 b/subdir/f1 | |||
|
954 | --- a/subdir/f1 | |||
|
955 | +++ b/subdir/f1 | |||
|
956 | @@ -1,3 +1,4 @@ | |||
|
957 | a | |||
|
958 | a | |||
|
959 | a | |||
|
960 | +b | |||
|
961 | ||||
|
962 | ||||
|
963 | Mock "Preserve chmod -x" | |||
|
964 | ||||
|
965 | $ chmod -x f1 | |||
|
966 | $ echo c >> f1 | |||
|
967 | $ hg record -d '22 0' -mab <<EOF | |||
|
968 | > y | |||
|
969 | > y | |||
|
970 | > y | |||
|
971 | > EOF | |||
|
972 | diff --git a/subdir/f1 b/subdir/f1 | |||
|
973 | 1 hunks, 1 lines changed | |||
|
974 | examine changes to 'subdir/f1'? [Ynesfdaq?] | |||
|
975 | @@ -2,3 +2,4 @@ | |||
|
976 | a | |||
|
977 | a | |||
|
978 | b | |||
|
979 | +c | |||
|
980 | record this change to 'subdir/f1'? [Ynesfdaq?] | |||
|
981 | ||||
|
982 | $ hg tip --config diff.git=True -p | |||
|
983 | changeset: 24:f4f718f27b7c | |||
|
984 | tag: tip | |||
|
985 | user: test | |||
|
986 | date: Thu Jan 01 00:00:22 1970 +0000 | |||
|
987 | summary: ab | |||
|
988 | ||||
|
989 | diff --git a/subdir/f1 b/subdir/f1 | |||
|
990 | --- a/subdir/f1 | |||
|
991 | +++ b/subdir/f1 | |||
|
992 | @@ -2,3 +2,4 @@ | |||
|
993 | a | |||
|
994 | a | |||
|
995 | b | |||
|
996 | +c | |||
|
997 | ||||
|
998 | ||||
|
999 | #endif | |||
|
1000 | ||||
888 | $ cd .. |
|
1001 | $ cd .. | |
889 |
|
1002 | |||
|
1003 | ||||
890 | Abort early when a merge is in progress |
|
1004 | Abort early when a merge is in progress | |
891 |
|
1005 | |||
892 | $ hg up 4 |
|
1006 | $ hg up 4 | |
@@ -1096,13 +1210,13 b' Ignore win32text deprecation warning for' | |||||
1096 | record this change to 'subdir/f1'? [Ynesfdaq?] |
|
1210 | record this change to 'subdir/f1'? [Ynesfdaq?] | |
1097 |
|
1211 | |||
1098 | $ hg tip -p |
|
1212 | $ hg tip -p | |
1099 |
changeset: 28: |
|
1213 | changeset: 28:* (glob) | |
1100 | tag: tip |
|
1214 | tag: tip | |
1101 | user: test |
|
1215 | user: test | |
1102 | date: Thu Jan 01 00:00:24 1970 +0000 |
|
1216 | date: Thu Jan 01 00:00:24 1970 +0000 | |
1103 | summary: w1 |
|
1217 | summary: w1 | |
1104 |
|
1218 | |||
1105 | diff -r 65ce23a81197 -r 287ad1f41a72 subdir/f1 |
|
1219 | diff -r ???????????? -r ???????????? subdir/f1 (glob) | |
1106 | --- a/subdir/f1 Thu Jan 01 00:00:23 1970 +0000 |
|
1220 | --- a/subdir/f1 Thu Jan 01 00:00:23 1970 +0000 | |
1107 | +++ b/subdir/f1 Thu Jan 01 00:00:24 1970 +0000 |
|
1221 | +++ b/subdir/f1 Thu Jan 01 00:00:24 1970 +0000 | |
1108 | @@ -3,3 +3,4 @@ |
|
1222 | @@ -3,3 +3,4 @@ |
General Comments 0
You need to be logged in to leave comments.
Login now