I'm attempting to run 2to3
on Windows machine where *.py files has Unix-style end-line characters. Running 2to3
modifies newline characters in output file.
MCVE:
print2.py content before
print "Hello, world!"\n
Executed command:
2to3 print2.py -w -n
print2.py content after
print("Hello, world!")\r\n
Expected content:
print("Hello, world!")\n
Is it possible to keep old newline characters when 2to3
conversion is performed?