yuja added a comment.
> +parser.add_argument( > + "--line", > + action="store_const", > + const=True, > + default=False, Nit: can be `action="store_true"` > vars = [b"%s=%s" % (k.encode('ascii'), filter(v).encode('ascii')) > for k, v in env] > > -out.write(b" ".join(vars)) > + > +# Print variables on out > +if args.line is False: Nit: `not args.line` > + vars = ["%s=%s" % (k, filter(v)) for k, v in env] Why not reuse the `vars` constructed above? It's carefully written to be Python3 safe. REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D5453 To: lothiraldan, #hg-reviewers Cc: yuja, mercurial-devel _______________________________________________ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel