comparison tests/test-rebase-abort @ 6906:808f03f61ebe

Add rebase extension
author Stefano Tortarolo <stefano.tortarolo@gmail.com>
date Mon, 18 Aug 2008 21:16:31 +0200
parents
children 93609576244e
comparison
equal deleted inserted replaced
6905:248e54a9456e 6906:808f03f61ebe
1 #!/bin/sh
2
3 echo "[extensions]" >> $HGRCPATH
4 echo "graphlog=" >> $HGRCPATH
5 echo "rebase=" >> $HGRCPATH
6
7 function cleanoutput {
8 sed -e 's/\(Rebase status stored to\).*/\1/' \
9 -e 's/\(Rebase status restored from\).*/\1/' \
10 -e 's/\(saving bundle to \).*/\1/'
11 }
12
13 hg init a
14 cd a
15 echo 'c1' >common
16 hg add common
17 hg commit -d '0 0' -u test -m "C1"
18
19 echo 'c2' >>common
20 hg commit -d '1 0' -u test -m "C2"
21
22 echo 'c3' >>common
23 hg commit -d '2 0' -u test -m "C3"
24
25 hg update -C 1
26 echo 'l1' >>extra
27 hg add extra
28 hg commit -d '3 0' -u test -m "L1"
29
30 sed -e 's/c2/l2/' common > common.new
31 mv common.new common
32 hg commit -d '4 0' -u test -m "L2"
33
34 hg glog --template '{rev}: {desc}\n'
35
36 echo
37 echo '% Conflicting rebase'
38 hg rebase -s 3 -d 2 2>&1 | cleanoutput
39
40 echo
41 echo '% Abort'
42 hg rebase --abort 2>&1 | cleanoutput
43
44 hg glog --template '{rev}: {desc}\n'