🐍 PIP (Python 包管理器) - 腾讯云镜像配置
复制以下命令到终端执行即可完成配置:
curl -sSL https://mirror2030.com/scripts/pip-tencent.sh | bash
✅ 所有脚本开源透明,可在下方查看完整内容
适合想了解具体步骤的用户:
pip config set global.index-url https://mirrors.cloud.tencent.com/pypi/simple/
完整脚本内容(可复制保存):
#!/bin/bash
# PIP 镜像配置 - 腾讯云
# 由 镜像加速站 自动生成
echo "正在配置 PIP 镜像源..."
# 永久配置
pip config set global.index-url https://mirrors.cloud.tencent.com/pypi/simple/
# 验证配置
echo "配置完成!当前镜像源:"
pip config get global.index-url
echo "\n✅ PIP 镜像源已成功配置为 腾讯云"
echo "如需恢复官方源,执行: pip config unset global.index-url"
⬇️ 下载脚本文件
💡 使用提示
- 配置后请重启终端或运行
source ~/.bashrc - 如遇问题可访问 教程中心 查看详细指南
- 建议定期测速选择最优镜像源