Python Conda Guide: Install Only the Small Environment

This guide explains how to create a minimal Conda environment (small env) instead of installing a full, heavy setup.

0) Install Conda First (if not installed)

If conda is not available on your machine, install Miniforge or Miniconda first.

Check whether Conda already exists:

conda --version

If you see command not found, install one of the options below.

# Download installer (example: macOS Apple Silicon)
curl -L -o Miniforge3.sh https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge3-MacOSX-arm64.sh
 
# Run installer
bash Miniforge3.sh
 
# Restart shell (or run:)
source ~/.zshrc

Windows

  1. Download Miniforge or Miniconda installer (.exe).
  2. Run installer with default options.
  3. Open Anaconda Prompt (or new terminal) and verify:
conda --version

Why a Small Environment?

Use a small environment when you only need lightweight Python tooling (for example: markdown processing, simple scripts, subtitle parsing, or basic utilities).

Benefits:

  • Faster install
  • Fewer dependency conflicts
  • Easier cleanup

Full Install Flow (From Zero)

  1. Install Conda (Miniforge/Miniconda).
  2. Open a new terminal and confirm conda --version.
  3. Create the small environment.
  4. Activate it.
  5. Install only the packages you need.

Option A: Create the Small Environment in One Command

conda create -n py-small python=3.11 pip -y

Activate it:

conda activate py-small

Option B: Use a Minimal environment.yml

Create a file named environment.small.yml:

name: py-small
channels:
  - conda-forge
  - defaults
dependencies:
  - python=3.11
  - pip

Then install:

conda env create -f environment.small.yml
conda activate py-small

Install Only What You Actually Need

After activation, install packages one by one (instead of a large requirements file):

pip install yt-dlp

Optional examples:

pip install jupyter
pip install pandas
pip install matplotlib

Tip: Keep this list short. Add packages only when needed.


Verify the Environment

python --version
which python
pip list
conda env list

You should see:

  • Python from py-small
  • Only a small set of installed packages

You can also list Conda environments with:

conda env list
conda info --envs

To check the currently active environment:

echo $CONDA_DEFAULT_ENV

Update Later (Incremental)

conda activate py-small
pip install <new-package>

Avoid reinstalling everything unless necessary.


Remove the Environment (Clean Up)

conda deactivate
conda env remove -n py-small

Common Mistakes

  1. Installing the full environment by accident.
  • Fix: create/activate py-small first, then install only required packages.
  1. Mixing environments.
  • Fix: always run conda activate py-small before installing/running Python tools.
  1. Installing too many optional libraries at the beginning.
  • Fix: start minimal; grow only when your task requires it.

Quick Start Summary

# 1) install Conda first (Miniforge/Miniconda) if needed
# 2) then run:
conda create -n py-small python=3.11 pip -y
conda activate py-small
pip install yt-dlp

That is enough for a lightweight Python setup.