https://github.com/cwksc/python-version-router
Python version router for window
https://github.com/cwksc/python-version-router
Last synced: 8 months ago
JSON representation
Python version router for window
- Host: GitHub
- URL: https://github.com/cwksc/python-version-router
- Owner: CWKSC
- License: mit
- Created: 2023-07-25T15:44:17.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2024-08-14T07:24:48.000Z (almost 2 years ago)
- Last Synced: 2024-08-14T08:45:48.539Z (almost 2 years ago)
- Language: PowerShell
- Size: 4.88 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# PythonVersionRouter
> [!CAUTION]
>
> I just to learn some powershell script
>
> This is no longer maintained and used
This script change different python version by modify PATH environment variable
It will remove all PythonXX\ and PythonXX\Scripts\ in PATH,
and add corresponding target version tag folder to PATH
Only temporarily works on the current process if without -keep flag
Add folder of this script to PATH first
Modify usepython-config.json to set root folder path for python folders If necessary
It should be `C:\\` or `C:\\Program Files\\`, by default it is `C:\\`
Usage: usepython `$version_tag` [-keep] [-root $path]
version_tag: 311, 310, 39, 38, 37, 36
keep: Set persistent modification, require admin permission
root: Specify root folder path for python folders instead of usepython-config.json
Example:
usepython 38
usepython 39 -keep
usepython 310 -root "C:\\"
usepython 311 -keep -root "C:\\Program Files\\"