Install miniconda
mamba is a faster, drop-in replacement for conda. You can swap almost all commands between conda & mamba...
The only difference is that you should still use
condaforactivationanddeactivation.
Code below will still use conda for compatibility, but use of mamba is strongly encouraged, especially for resolving/installing environments with complicated dependencies.
Install mamba to the base environment.
Check if conda is in PATH and set as default python
conda install mamba -n base -c conda-forgeNote: After installing mamba, leave base environment untouched and work only in other envs
conda create --name <env_name> python=3.7 <package_1> <other-channel::package_2> ...conda create --name <myclone> --clone <exisiting_env>conda env create -f /path/to/environment.ymlActivate an environment to use it (or to install packages to it):
conda activate <env_nameInstall conda environment to jupyter:
python -m ipykernel install --user --name=<env_name>Export exact specifications:
conda env export --name ENVNAME > environment.ymlExport an environment for cross-platform:
conda env export --name ENVNAME --from-history > environment.ymlconda remove --name <env_name> --allIMPORTANT: setting to revision #0 basically uninstalls all environments! Use --revision 1 at minimum
conda list --revisions # lists all changes in order
conda install --revision <rev_num> # resets state to <rev_num>