2to3

Automated Python 2 to 3 code translation. More information: https://docs.python.org/3/library/2to3.html.…

2to3

Automated Python 2 to 3 code translation. More information: https://docs.python.org/3/library/2to3.html.

2to3 {{path/to/file.py}}

2to3 --write {{path/to/file.py}}

2to3 --write {{file.py}} --fix={{raw_input}} --fix={{print}}

2to3 --nofix={{raw_input}} --fix={{print}} example.py

2to3 --list-fixes

2to3 --output-dir={{path/to/code_python3_version}} --write-unchanged-files --nobackups {{path/to/code_python2_version}}

Также может быть вам интересно:
КодТрюки BashНастройкиТерминал/Консоль
← [[ 7z →