My python project runs on a conda virtual environment. I install packages on the environment with conda install whenever that package is available for installing th
conda install
If you have installed pip with anaconda and used it to install the packages then conda-env does this automatically.
pip
anaconda
conda-env
So basically you can export your environment with
conda env export -n > environment.yml
Otherwise
Please refer to this link