Skip to content

Instantly share code, notes, and snippets.

@kyrcha
Last active January 3, 2019 12:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kyrcha/6f5c75c7dc1765aec41ec47568bcf400 to your computer and use it in GitHub Desktop.
Save kyrcha/6f5c75c7dc1765aec41ec47568bcf400 to your computer and use it in GitHub Desktop.
Anaconda commands

Checkout all the packages in the default conda environment:

conda list

Upgrading conda and packages:

conda upgrade conda
conda upgrade --all

Installing packages examples:

conda install numpy
conda install numpy scipy pandas
conda install numpy=1.10

Searching:

conda search beautifulsoup

Creating environments to isolate your projects:

conda create -n <env_name> <list of packages>
conda create -n py3 python=3
conda create -n py2 python=2

Enter/Leave an environment:

conda activate <env_name>
conda deactivate

Saving/Loading environments

conda env export > environment.yaml 
conda env create -f environment.yaml

Checking environments:

conda env list

Remove environments:

conda env remove -n <env_name>

Sharing environments:

pip freeze 

or

conda list -- export > requirements.txt

and to re-create the environment

conda create --name <env_name> --file requirements.txt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment