equal
deleted
inserted
replaced
|
1 #!/bin/sh |
|
2 |
|
3 hg init |
|
4 echo foo > a |
|
5 hg add a |
|
6 hg commit -m "1" -d "0 0" |
|
7 |
|
8 echo bar > b |
|
9 hg add b |
|
10 hg remove a |
|
11 |
|
12 echo "%%% should show a removed and b added" |
|
13 hg status |
|
14 |
|
15 echo "reverting..." |
|
16 hg revert |
|
17 |
|
18 echo "%%% should show b unknown and a back to normal" |
|
19 hg status |
|
20 |
|
21 rm b |
|
22 |
|
23 hg co -C 0 |
|
24 echo foo-a > a |
|
25 hg commit -m "2a" -d "0 0" |
|
26 |
|
27 hg co -C 0 |
|
28 echo foo-b > a |
|
29 hg commit -m "2b" -d "0 0" |
|
30 |
|
31 HGMERGE=true hg update -m 1 |
|
32 |
|
33 echo "%%% should show foo-b" |
|
34 cat a |
|
35 |
|
36 echo bar > b |
|
37 hg add b |
|
38 rm a |
|
39 hg remove a |
|
40 |
|
41 echo "%%% should show a removed and b added" |
|
42 hg status |
|
43 |
|
44 echo "reverting..." |
|
45 hg revert |
|
46 |
|
47 echo "%%% should show b unknown and a marked modified (merged)" |
|
48 hg status |
|
49 |
|
50 echo "%%% should show foo-b" |
|
51 cat a |
|
52 |