avatar

目录
python version management

Python Version Management

https://chatgpt.com/g/g-2DQzU5UZl-code-copilot/c/66ecf091-aa50-8011-bb50-250258dbabff

This is chatgpt suggestion to manage python in a better way…

solution:
in windows:

  1. for cmd, create /user/script, for each version of official python, create python312.bat with:
    bat
    1
    2
    @echo off
    "d:\sw_install\python_312\python.exe" %*
  2. for git bash, create/user/.bash_profile, for each version of official python
    bash
    1
    2
    alias python312='winpty /d/sw_install/python_312/python.exe'
    }
    create .bashrc file which should be like this:
    Code
    1
    2
    3
    if [ -f ~/.bash_profile ]; then
    . ~/.bash_profile
    fi

This is to ensure that bash is loading the alias function in .bash_profile no matter where you open your bash
https://chatgpt.com/c/66ece93c-738c-8011-a2f6-fa3eed19a82a
This is a frustrated discussion of how to manage python between pip and conda


评论