equal
deleted
inserted
replaced
1 #!/bin/sh |
|
2 |
|
3 "$TESTDIR/hghave" inotify || exit 80 |
|
4 |
|
5 hg init repo1 |
|
6 cd repo1 |
|
7 |
|
8 touch a b c d e |
|
9 mkdir dir |
|
10 mkdir dir/bar |
|
11 touch dir/x dir/y dir/bar/foo |
|
12 |
|
13 hg ci -Am m |
|
14 cd .. |
|
15 hg clone repo1 repo2 |
|
16 |
|
17 echo "[extensions]" >> $HGRCPATH |
|
18 echo "inotify=" >> $HGRCPATH |
|
19 |
|
20 cd repo2 |
|
21 echo b >> a |
|
22 # check that daemon started automatically works correctly |
|
23 # and make sure that inotify.pidfile works |
|
24 hg --config "inotify.pidfile=../hg2.pid" status |
|
25 |
|
26 # make sure that pidfile worked. Output should be silent. |
|
27 kill `cat ../hg2.pid` |
|
28 |
|
29 cd ../repo1 |
|
30 echo % inserve |
|
31 hg inserve -d --pid-file=hg.pid |
|
32 cat hg.pid >> "$DAEMON_PIDS" |
|
33 |
|
34 # let the daemon finish its stuff |
|
35 sleep 1 |
|
36 |
|
37 echo % cannot start, already bound |
|
38 hg inserve |
|
39 |
|
40 # issue907 |
|
41 hg status |
|
42 echo % clean |
|
43 hg status -c |
|
44 echo % all |
|
45 hg status -A |
|
46 |
|
47 echo '% path patterns' |
|
48 echo x > dir/x |
|
49 hg status . |
|
50 hg status dir |
|
51 cd dir |
|
52 hg status . |
|
53 cd .. |
|
54 |
|
55 #issue 1375 |
|
56 #Testing that we can remove a folder and then add a file with the same name |
|
57 echo % issue 1375 |
|
58 |
|
59 mkdir h |
|
60 echo h > h/h |
|
61 hg ci -Am t |
|
62 hg rm h |
|
63 |
|
64 echo h >h |
|
65 hg add h |
|
66 |
|
67 hg status |
|
68 hg ci -m0 |
|
69 |
|
70 # Test for issue1735: inotify watches files in .hg/merge |
|
71 hg st |
|
72 |
|
73 echo a > a |
|
74 |
|
75 hg ci -Am a |
|
76 hg st |
|
77 |
|
78 echo b >> a |
|
79 hg ci -m ab |
|
80 hg st |
|
81 |
|
82 echo c >> a |
|
83 hg st |
|
84 |
|
85 HGMERGE=internal:local hg up 0 |
|
86 hg st |
|
87 |
|
88 HGMERGE=internal:local hg up |
|
89 hg st |
|
90 |
|
91 # Test for 1844: "hg ci folder" will not commit all changes beneath "folder" |
|
92 mkdir 1844 |
|
93 echo a > 1844/foo |
|
94 hg add 1844 |
|
95 hg ci -m 'working' |
|
96 |
|
97 echo b >> 1844/foo |
|
98 hg ci 1844 -m 'broken' |
|
99 |
|
100 # Test for issue884: "Build products not ignored until .hgignore is touched" |
|
101 echo '^build$' > .hgignore |
|
102 hg add .hgignore |
|
103 hg ci .hgignore -m 'ignorelist' |
|
104 |
|
105 # Now, lets add some build products... |
|
106 mkdir build |
|
107 touch build/x |
|
108 touch build/y |
|
109 |
|
110 # build/x & build/y shouldn't appear in "hg st" |
|
111 hg st |
|
112 |
|
113 kill `cat hg.pid` |
|