自动化导入

今天项目部署测试:手动导入太麻烦写了个自动化导入如例(补充前文):

import pip
from subprocess import call
f= open("boke.txt")
for dist in f.readlines():
    #print(dist,end="")
    call("pip install " + dist +'',shell=True)

遇到错误自动跳过

原文地址:https://www.cnblogs.com/yongqi-wang/p/13693151.html