appveyor-bootstrap.py 文件源码

python
阅读 22 收藏 0 点赞 0 评论 0

项目:python-twelve-tone 作者: accraze 项目源码 文件源码
def install_python(version, arch, home):
    print("Installing Python", version, "for", arch, "bit architecture to", home)
    if exists(home):
        return

    path = download_python(version, arch)
    print("Installing", path, "to", home)
    success = False
    for cmd in INSTALL_CMD[version]:
        cmd = [part.format(home=home, path=path) for part in cmd]
        print("Running:", " ".join(cmd))
        try:
            check_call(cmd)
        except CalledProcessError as exc:
            print("Failed command", cmd, "with:", exc)
            if exists("install.log"):
                with open("install.log") as fh:
                    print(fh.read())
        else:
            success = True
    if success:
        print("Installation complete!")
    else:
        print("Installation failed")
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号