annotate tests/test-1102 @ 10428:e553a425751d stable

convert: differentiate between IOError and OSError on commitctx() The IOError exception is overloaded to mean 'this file was deleted in the current commit'. Separate the code that handles IOError and file deletion from general OSError exceptions. The latter are real errors, but IOError is not always a throwable error. This solves the accidental marking of files as 'deleted' in commits that try to write for example in .hg/store/data revlogs that the current user has no permission to modify (a normal OSError that should abort the current commit). Changed by pmezard: use getattr() to be on the safe side.
author Giorgos Keramidas <keramida@ceid.upatras.gr>
date Thu, 11 Feb 2010 23:15:42 +0200
parents 938eddd76237
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
6671
938eddd76237 tag: record tag we're superseding, if any (issue 1102)
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
1 #!/bin/sh
938eddd76237 tag: record tag we're superseding, if any (issue 1102)
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
2
938eddd76237 tag: record tag we're superseding, if any (issue 1102)
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
3 rm -rf a
938eddd76237 tag: record tag we're superseding, if any (issue 1102)
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
4 hg init a
938eddd76237 tag: record tag we're superseding, if any (issue 1102)
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
5 cd a
938eddd76237 tag: record tag we're superseding, if any (issue 1102)
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
6 echo a > a
938eddd76237 tag: record tag we're superseding, if any (issue 1102)
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
7 hg ci -Am0
938eddd76237 tag: record tag we're superseding, if any (issue 1102)
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
8 hg tag t1 # 1
938eddd76237 tag: record tag we're superseding, if any (issue 1102)
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
9 hg tag --remove t1 # 2
938eddd76237 tag: record tag we're superseding, if any (issue 1102)
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
10
938eddd76237 tag: record tag we're superseding, if any (issue 1102)
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
11 hg co 1
938eddd76237 tag: record tag we're superseding, if any (issue 1102)
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
12 hg tag -r0 t1
938eddd76237 tag: record tag we're superseding, if any (issue 1102)
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
13 hg tags
938eddd76237 tag: record tag we're superseding, if any (issue 1102)
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
14
938eddd76237 tag: record tag we're superseding, if any (issue 1102)
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
15
938eddd76237 tag: record tag we're superseding, if any (issue 1102)
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
16