当更新安装Python时, 卸载之前的安装, 会连带pip之前安装的库文件一同卸载, 可以使用命令导出已安装的库的列表到文件, 等安装完新的Python后, 在通过文件批量安装库文件

1.导出安装列表到文件

pip freeze > requirements.txt

2.通过文件批量安装库文件(使用清华的源)

pip install -r requirements.txt -i https://pypi.tuna.tsinghua.edu.cn/simple

相关文章:

  • 2021-12-09
  • 2021-06-04
  • 2021-07-25
  • 2021-09-12
  • 2021-05-26
  • 2021-06-01
  • 2021-12-26
猜你喜欢
  • 2021-09-25
  • 2021-06-12
  • 2021-09-23
  • 2021-07-06
  • 2021-07-29
  • 2022-12-23
  • 2021-07-23
相关资源
相似解决方案