comparison mercurial/commands.py @ 712:b4f0fad0ea64

Merge with myself. -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Merge with myself. manifest hash: e47e1ba87ecb28a08f819401fd8c2a88bc830261 -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.1 (GNU/Linux) iD8DBQFC168rW7P1GVgWeRoRAmknAJ0ea1BrnM1KSnfPqkYpurFpV+booACcDGNh ka6ciaH1pQLhOyKgqdbqwOA= =pOV4 -----END PGP SIGNATURE-----
author Thomas Arendsen Hein <thomas@intevation.de>
date Fri, 15 Jul 2005 13:42:19 +0100
parents 734712f37de3 ca9353f43345
children 29fcd195e056
comparison
equal deleted inserted replaced
711:734712f37de3 712:b4f0fad0ea64
1021 if ".hgtags" in x: 1021 if ".hgtags" in x:
1022 ui.warn("abort: working copy of .hgtags is changed!\n") 1022 ui.warn("abort: working copy of .hgtags is changed!\n")
1023 ui.status("(please commit .hgtags manually)\n") 1023 ui.status("(please commit .hgtags manually)\n")
1024 return -1 1024 return -1
1025 1025
1026 add = not os.path.exists(repo.wjoin(".hgtags"))
1027 repo.wfile(".hgtags", "ab").write("%s %s\n" % (r, name)) 1026 repo.wfile(".hgtags", "ab").write("%s %s\n" % (r, name))
1028 if add: 1027 if repo.dirstate.state(".hgtags") == '?':
1029 repo.add([".hgtags"]) 1028 repo.add([".hgtags"])
1030 1029
1031 if not opts['text']: 1030 if not opts['text']:
1032 opts['text'] = "Added tag %s for changeset %s" % (name, r) 1031 opts['text'] = "Added tag %s for changeset %s" % (name, r)
1033 1032