Mercurial > public > mercurial-scm > hg
comparison mercurial/commands.py @ 617:285965ddca41
open .hgtags as binary
# HG changeset patch
# User thananck@yahoo.com
# Node ID 2bd20bb06f817796d76b8e126f4a685426c4faf4
# Parent 7a240687674e6cf5a8dfd45973d7e3978b89af79
open .hgtags as binary
The '.hgtags' file, in tag command, is opened as binary for interoperability with the other OS
author | thananck@yahoo.com |
---|---|
date | Mon, 04 Jul 2005 12:39:21 -0800 |
parents | ad2999fad721 |
children | 4051b78c53c7 |
comparison
equal
deleted
inserted
replaced
616:d45d1c90032e | 617:285965ddca41 |
---|---|
886 ui.status("(please commit .hgtags manually)\n") | 886 ui.status("(please commit .hgtags manually)\n") |
887 return -1 | 887 return -1 |
888 | 888 |
889 add = 0 | 889 add = 0 |
890 if not os.path.exists(repo.wjoin(".hgtags")): add = 1 | 890 if not os.path.exists(repo.wjoin(".hgtags")): add = 1 |
891 repo.wfile(".hgtags", "a").write("%s %s\n" % (r, name)) | 891 repo.wfile(".hgtags", "ab").write("%s %s\n" % (r, name)) |
892 if add: repo.add([".hgtags"]) | 892 if add: repo.add([".hgtags"]) |
893 | 893 |
894 if not opts['text']: | 894 if not opts['text']: |
895 opts['text'] = "Added tag %s for changeset %s" % (name, r) | 895 opts['text'] = "Added tag %s for changeset %s" % (name, r) |
896 | 896 |