Mercurial > hg > mercurial-crew-with-dirclash
annotate tests/test-merge2 @ 508:42a660abaf75
[PATCH] Harden os.system
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
[PATCH] Harden os.system
From: Bryan O'Sullivan <bos@serpentine.com>
Add util.system function. This is similar to os.system, but will
either succeed (if the process finishes with a zero exit code) or raise
a util.CommandError (if the process exits uncleanly or is killed by
a signal).
Add util.explain_exit function. This tends to be ubiquitous in code
that calls other processes, and must describe what has gone wrong.
Change some uses of os.system over to util.system.
manifest hash: e3bf4adcac5b915432ec0af00efdbcef86bea4b1
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)
iD8DBQFCwSipywK+sNU5EO8RAr0RAJkBDt8XQ7mYQAWNHNgTOVt1eyWU1QCfe1oO
2OwxyWqpbRNACVJHHfZ3/Xw=
=OaRX
-----END PGP SIGNATURE-----
author | mpm@selenic.com |
---|---|
date | Tue, 28 Jun 2005 02:38:33 -0800 |
parents | feadc9697b43 |
children | 7e4843b7efd2 |
rev | line source |
---|---|
409 | 1 #!/bin/sh -x |
2 | |
3 mkdir t | |
4 cd t | |
5 hg init | |
6 echo This is file a1 > a | |
7 hg add a | |
8 hg commit -t "commit #0" -d "0 0" -u user | |
9 echo This is file b1 > b | |
10 hg add b | |
11 hg commit -t "commit #1" -d "0 0" -u user | |
12 rm b | |
13 hg update 0 | |
14 echo This is file b2 > b | |
15 hg add b | |
16 hg commit -t "commit #2" -d "0 0" -u user | |
17 cd ..; /bin/rm -rf t | |
18 | |
19 mkdir t | |
20 cd t | |
21 hg init | |
22 echo This is file a1 > a | |
23 hg add a | |
24 hg commit -t "commit #0" -d "0 0" -u user | |
25 echo This is file b1 > b | |
26 hg add b | |
27 hg commit -t "commit #1" -d "0 0" -u user | |
28 rm b | |
29 hg update 0 | |
30 echo This is file b2 > b | |
31 hg commit -A -t "commit #2" -d "0 0" -u user | |
32 cd ..; /bin/rm -rf t | |
33 | |
34 mkdir t | |
35 cd t | |
36 hg init | |
37 echo This is file a1 > a | |
38 hg add a | |
39 hg commit -t "commit #0" -d "0 0" -u user | |
40 echo This is file b1 > b | |
41 hg add b | |
42 hg commit -t "commit #1" -d "0 0" -u user | |
43 rm b | |
44 hg remove b | |
45 hg update 0 | |
46 echo This is file b2 > b | |
47 hg commit -A -t "commit #2" -d "0 0" -u user | |
48 cd ..; /bin/rm -rf t |