If your concern is what Python version is executed when calling python
in a console, then an alias or a stub script are the two ways to go.
This post will explain you how you can do this on Windows.
The alias way, just like it would be on a Unix system, is to create an alias, either temporary to the session or permanent, so that python
now means C:\Python27\python
, or whatever version you want.
The script approach consists in putting a script named python
in a directory referred to in your PATH
, and have that script run the right version of Python.
I highly doubt that this will affect all the batch scripts that call python
, but it will definitely fire the right Python when you'll type python
in a console.
Now, if you're concerned about what version a script is executed with, you can specify an explicit version with a shebang line, or manually select it by right-clicking the .py
file and clicking open with
.