Mercurial > public > mercurial-scm > hg-stable
comparison mercurial/debugcommands.py @ 35214:d4b108fdf423
py3: use encoding.strtolocal() to convert string to bytes
Differential Revision: https://phab.mercurial-scm.org/D1557
author | Pulkit Goyal <7895pulkit@gmail.com> |
---|---|
date | Wed, 29 Nov 2017 08:40:25 +0530 |
parents | b45a9d121b53 |
children | f77121b6bf1b |
comparison
equal
deleted
inserted
replaced
35213:4ee493ea1c13 | 35214:d4b108fdf423 |
---|---|
719 elif nodates: | 719 elif nodates: |
720 timestr = 'set ' | 720 timestr = 'set ' |
721 else: | 721 else: |
722 timestr = time.strftime(r"%Y-%m-%d %H:%M:%S ", | 722 timestr = time.strftime(r"%Y-%m-%d %H:%M:%S ", |
723 time.localtime(ent[3])) | 723 time.localtime(ent[3])) |
724 timestr = encoding.strtolocal(timestr) | |
724 if ent[1] & 0o20000: | 725 if ent[1] & 0o20000: |
725 mode = 'lnk' | 726 mode = 'lnk' |
726 else: | 727 else: |
727 mode = '%3o' % (ent[1] & 0o777 & ~util.umask) | 728 mode = '%3o' % (ent[1] & 0o777 & ~util.umask) |
728 ui.write("%c %s %10d %s%s\n" % (ent[0], mode, ent[2], timestr, file_)) | 729 ui.write("%c %s %10d %s%s\n" % (ent[0], mode, ent[2], timestr, file_)) |