Python aliases under Windows?

Kirill Balunov kirillbalunov at
Tue Apr 3 05:24:51 EDT 2018

Perhaps this is a silly question but still...There is PEP 394 "The "python"
Command on Unix-Like Systems" which I find very reasonable, no matter how
it is respected. Why was not _somewhat_ the same done for Windows?

Sometimes I use, especially in IPython, to run externally:
! python3 -m dis <module>
! python3 -m timeit ...
! python3 -m pip install ...

And to make this work the same under Windows, the first step which I do
after installation is to copy `python.exe` and rename it to `python3.exe`
(for python 2.7 copy `python.exe` and rename it to `python2.exe`). May be
there is a better way to do this under Windows, I would like to know?  This
copy-rename works for me, but it will not work for someone who does not
have administrative rights.

p.s.: I know there is a `py` launcher under Windows, but is does not help
in this situation.

With kind regards,

More information about the Python-list mailing list