Add mechanism to control wether global files `~/.conda/environments.txt` are written to or not
Troubleshooting docs
- [X] My problem is not solved in the Troubleshooting docs
How did you install Mamba?
Micromamba
Search tried in issue tracker
NA
Latest version of Mamba
- [X] My problem is not solved with the latest version
Tried in Conda?
Not applicable
Describe your issue
micromamba notes down all environments in the ~/.conda/environments.txt global file.
Some people that use micromamba more programatically do not like that it writes to a global file. We could add a boolean variable to the configuration that controls this behavior and prevents micromamba from writing to this file.
mamba info / micromamba info
No response
Logs
No response
environment.yml
No response
~/.condarc
No response
This would be nice!
Not micromamba-specific, but I literally have code in my .bashrc to scrub environments.txt of what should otherwise be hidden environments (e.g., Snakemake environments). It would be helpful if we could be more deliberate about what we want exposed to the interactive user via environments.txt.
Check https://github.com/conda/conda/pull/12924. I think we can agree on the same context key (register_envs) to avoid duplication.
Added https://github.com/mamba-org/mamba/pull/2802
@jaimergp I think we still need to wire this up to CLI / config file reading etc., right?
No clue. In conda adding it to the context object exposes it in the config file and the env var, and I didn't add it as a CLI flag. I am guessing now that it's not that magic here in mambaland so let me know what needs to be done and I'll try my best 😬