centos7 安装miniconda

1.先下载安装脚本

bash 复制代码
wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh

2.开始安装

bash 复制代码
bash Miniconda3-latest-Linux-x86_64.sh -b -p ~/miniconda3

-b: 以批处理模式安装,无需交互

-p:安装目录(不用提前创建)

3.添加环境变量

3.1针对用户

bash 复制代码
echo 'export PATH="/opt/miniconda3/bin:$PATH"' >> ~/.bashrc

3.2针对所有用户

bash 复制代码
echo 'export PATH="/opt/miniconda3/bin:$PATH"' >> /etc/profile

4.检查安装

bash 复制代码
# 命令
conda --version
# 结果
conda 23.9.0

5.初始化

bash 复制代码
source ~/.bashrc    # 单个用户
source /etc/profile # 全局用户
conda init bash     # 初始化
conda activate base   # 激活base环境
conda create -n common python=3.10  # 创建一个名为common的python版本为3.10的环境
相关推荐
明月_清风1 天前
从“能用”到“专业”:构建生产级装饰器与三层逻辑拆解
后端·python
曲幽1 天前
数据库实战:FastAPI + SQLAlchemy 2.0 + Alembic 从零搭建,踩坑实录
python·fastapi·web·sqlalchemy·db·asyncio·alembic
用户8356290780512 天前
Python 实现 PowerPoint 形状动画设置
后端·python
ponponon2 天前
时代的眼泪,nameko 和 eventlet 停止维护后的项目自救,升级和替代之路
python
Flittly2 天前
【从零手写 ClaudeCode:learn-claude-code 项目实战笔记】(5)Skills (技能加载)
python·agent
敏编程2 天前
一天一个Python库:pyarrow - 大规模数据处理的利器
python
Flittly2 天前
【从零手写 ClaudeCode:learn-claude-code 项目实战笔记】(4)Subagents (子智能体)
python·agent
明月_清风2 天前
Python 装饰器前传:如果不懂“闭包”,你只是在复刻代码
后端·python
明月_清风2 天前
打破“死亡环联”:深挖 Python 分代回收与垃圾回收(GC)机制
后端·python
ZhengEnCi3 天前
08c. 检索算法与策略-混合检索
后端·python·算法