Contents

Conda Basic

Miniconda3 (suggested)

getting-started

Commands

  • List environments
conda info -e
# or
conda env list
  • Activate base environment
actconda # personal alias
actconda='eval "$(/home/rbach/rbox.local/var/miniconda3/bin/conda shell.zsh hook)"'
  • Deactivate current environment
conda deactivate
  • Activate an environment
conda activate aistudy
  • Create an environment
conda create -n aistudy python=3.11
  • Create an environment from a configuration file
conda env create -f aistudy.yml

aistudy.yml

name: aistudy
channels:
  - defaults
  - conda-forge
dependencies:
  - python=3.12
  - jupyterlab
  - r-base
  - r-essentials
  - numpy
  - pandas
  - scipy
  - scikit-learn
  - r-irkernel
  • Remove an environment
conda env remove -n aistudy
  • List all packages in the current environment
conda list