在Git Bash里使用Python

目录

在Git Bash中使用 python 运行代码时报错

Python was not found; run without arguments to install from the Microsoft Store, or disable this shortcut from Settings > Manage App Execution Aliases.

解决办法

  1. 在命令前加上 winpty

    winpty python

  2. 修改配置文件

    echo "alias python='winpty python.exe'" >> ~/.bash_profile

打赏一个呗

取消

感谢您的支持,我会继续努力的!

扫码支持
扫码支持
扫码打赏,你说多少就多少

打开支付宝扫一扫,即可进行扫码打赏哦