Mercurial > hgbook
comparison ja/examples/backout @ 290:b0db5adf11c1 ja_root
fork Japanese translation.
author | Yoshiki Yazawa <yaz@cc.rim.or.jp> |
---|---|
date | Wed, 06 Feb 2008 17:43:11 +0900 |
parents | en/examples/backout@5fc4a45c069f |
children | 896ab6eaf1c6 |
comparison
equal
deleted
inserted
replaced
289:7be02466421b | 290:b0db5adf11c1 |
---|---|
1 #!/bin/bash | |
2 | |
3 # We have to fake the merges here, because they cause conflicts with | |
4 # three-way command-line merge, and kdiff3 may not be available. | |
5 | |
6 export HGMERGE=$(mktemp) | |
7 echo '#!/bin/sh' >> $HGMERGE | |
8 echo 'echo first change > "$1"' >> $HGMERGE | |
9 echo 'echo third change >> "$1"' >> $HGMERGE | |
10 chmod 700 $HGMERGE | |
11 | |
12 #$ name: init | |
13 | |
14 hg init myrepo | |
15 cd myrepo | |
16 echo first change >> myfile | |
17 hg add myfile | |
18 hg commit -m 'first change' | |
19 echo second change >> myfile | |
20 hg commit -m 'second change' | |
21 | |
22 #$ name: simple | |
23 | |
24 hg backout -m 'back out second change' tip | |
25 cat myfile | |
26 | |
27 #$ name: simple.log | |
28 #$ ignore: \s+200[78]-.* | |
29 | |
30 hg log --style compact | |
31 | |
32 #$ name: non-tip.clone | |
33 | |
34 cd .. | |
35 hg clone -r1 myrepo non-tip-repo | |
36 cd non-tip-repo | |
37 | |
38 #$ name: non-tip.backout | |
39 | |
40 echo third change >> myfile | |
41 hg commit -m 'third change' | |
42 hg backout --merge -m 'back out second change' 1 | |
43 | |
44 #$ name: non-tip.cat | |
45 cat myfile | |
46 | |
47 #$ name: manual.clone | |
48 | |
49 cd .. | |
50 hg clone -r1 myrepo newrepo | |
51 cd newrepo | |
52 | |
53 #$ name: manual.backout | |
54 | |
55 echo third change >> myfile | |
56 hg commit -m 'third change' | |
57 hg backout -m 'back out second change' 1 | |
58 | |
59 #$ name: manual.log | |
60 | |
61 hg log --style compact | |
62 | |
63 #$ name: manual.parents | |
64 | |
65 hg parents | |
66 | |
67 #$ name: manual.heads | |
68 | |
69 hg heads | |
70 | |
71 #$ name: manual.cat | |
72 | |
73 cat myfile | |
74 | |
75 #$ name: manual.merge | |
76 | |
77 hg merge | |
78 hg commit -m 'merged backout with previous tip' | |
79 cat myfile | |
80 | |
81 #$ name: | |
82 | |
83 rm $HGMERGE |