[PATCH 1 of 2] py3: byteify sys.argv in gendoc.py

Yuya Nishihara yuya at tcha.org
Fri Dec 21 21:41:51 EST 2018


On Fri, 21 Dec 2018 00:13:15 -0500, Matt Harbison wrote:
> # HG changeset patch
> # User Matt Harbison <matt_harbison at yahoo.com>
> # Date 1545347549 18000
> #      Thu Dec 20 18:12:29 2018 -0500
> # Node ID 5323f3f275a8522e445e8029acc5cac6b636f1c8
> # Parent  6d49a573ba57caf690db1a82dc682a9cadb1f038
> py3: byteify sys.argv in gendoc.py

>  if __name__ == "__main__":
>      doc = b'hg.1.gendoc'
>      if len(sys.argv) > 1:
> -        doc = sys.argv[1]
> +        doc = encoding.strtolocal(sys.argv[1])

There's one more sys.argv[1] below.


More information about the Mercurial-devel mailing list