install.py 683 字节
Newer Older
F
feilong 已提交
1
# -*- coding: UTF-8 -*-
F
feilong 已提交
2
# 作者:huanhuilong
F
feilong 已提交
3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
# 标题:Python numpy 安装
# 描述:正确打印安装顺序

def test():
    installs = [
        "1. pip install numpy",
        "3. 还可以试试豆瓣的源:pip install numpy -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com",
        "2. 如果装不了,就试试阿里的源:pip install numpy -i http://mirrors.aliyun.com/pypi/simple --trusted-host mirrors.aliyun.com",
    ]

    installs.sort(key=lambda i: i[0])
    for step in installs:
        items = step.split(":")
        print(items[0])
        if len(items) > 1:
            print(f"  {items[1]}")


if __name__ == '__main__':
    test()