8

The documentation states that cloning works this way:

conda create --name myclone --clone myenv

However, this will always default to creating the environment myclone into the home directory where I have little disk storage. I would like to have conda create a clone onto another path where I have a huge amount of storage.

I would have expected something like this to exist, but alas:

conda create --name myclone --clone myenv --destination /path/to/huge/storage

Also, the --path and --name cannot be used at the same time.

What are my options? I need to work with conda, that is changing my hardware infrastructure is not an option, in case you would suggest me to increase my home directory space etc.

Or are we dealing with a conda limitation here?

AMC
  • 2,642
  • 7
  • 13
  • 35
Shailen
  • 7,909
  • 3
  • 29
  • 37
  • Have you seen [Specifying a location for an environment](https://docs.conda.io/projects/conda/en/latest/user-guide/tasks/manage-environments.html#specifying-a-location-for-an-environment) ? – AMC Oct 01 '20 at 23:49
  • @AMC - somehow this didn't come up through my research and apparently this solves my question (prefix and modifying condarc). Can you please post this as an answer and I will approve it as an accepted answer? Thanks. – Shailen Oct 03 '20 at 01:21
  • 1
    _Can you please post this as an answer and I will approve it as an accepted answer?_ I'm not sure if that is the right thing to do actually, since I would just be duplicating information which is already in the official documentation. – AMC Oct 03 '20 at 20:37
  • 1
    Does this answer your question? [how to specify new environment location for conda create](https://stackoverflow.com/questions/37926940/how-to-specify-new-environment-location-for-conda-create) – AMC Oct 03 '20 at 20:37

1 Answers1

5

Navigate in the destination folder and open terminal window or use cd command directly from terminal to move there. Then:

$ conda create --prefix=myclone --clone myenv

Note that if your base enviroment is not in the default conda directory you have to specify the path replacing myenv with path/to/myenv.