Activating conda environment with its full path

Update for conda 4.4 and up:

You need to specify the conda environment path to activate. The new conda activate command should not need the full path to an "activate script" any longer, since the command is now "built-in" to conda. So something like:

conda activate (fullpath)/env-name-here

should work.


The command you have specified activates the root environment because you have not given conda an environment to activate, and root is the default. If you want to activate a particular environment, you can certainly do so with the full path to the activate script, for instance

source (full path to main Anaconda directory)/bin/activate (fullpath)/env-name-here
                                                           ^^^^^^^^^^^^^^^^^^^^^^^^
                                                           You're missing this part

You can activate an environment that is not in your conda environment list by passing the path to the environment. For example you can create an environment in any directory you want with the -p argument. Like so:

conda create -p /path/to/some/location/mytestenv/ python=3.5

This will NOT show up in conda env list, but you can activate it with:

source activate /path/to/some/location/mytestenv