今天看到個人foreman開始報錯去詢問才發現。咱們的python包管理工具已經從pip總體遷移到了conda。。最近的遷移真的很是多。。前端也在遷移打包前端
跟着發的教程弄了半天總算搞定,可是我很是疑惑。python
爲何疑惑。。由於既然都是關於python的包管理工具爲何有了pip 咱們還須要conda?在stackoverflow上搜到了答案 因此。我只作中文搬運 不作過多的污染ide
Having been involved in the python world for so long, we are all aware of pip, easy_install, and virtualenv, but these tools did not meet all of our specific requirements. The main problem is that they are focused around Python, neglecting non-Python library dependencies, such as HDF5, MKL, LLVM, etc., which do not have a setup.py in their source code and also do not install files into Python’s site-packages directory.工具
So Conda is a packaging tool and installer that aims to do more than what pip does; handle library dependencies outside of the Python packages as well as the Python packages themselves. Conda also creates a virtual environment, like virtualenv does.ui
As such, Conda should be compared to Buildout perhaps, another tool that lets you handle both Python and non-Python installation tasks.spa
Because Conda introduces a new packaging format, you cannot use pip and Conda interchangeably; pip cannot install the Conda package format. You can use the two tools side by side but they do not interoperate either.
在python的世界裏也浸淫多年了,咱們早已習慣有 pip ,easy_install 和virtualenv的世界,可是這些工具沒有解決咱們全部的需求哦。這其中主要的問題是他們所有都集中解決關於python相關問題而忽略了非python庫的依賴關係。(這句我沒他看明白),就像 HDF5, MKL LLVM,etc等,在他們的源碼中並無setup.py這種東西並且也沒有安裝文件在python的site-packages 目錄中。code
全部conda就是一個包管理工具和安裝工具,他就是要作比pip更多的事情;在python-site-packages以外管理python 庫依賴關係。 並且conda一樣也像virtualenv同樣建立一個虛擬環境。
conda可讓你同時管理安裝處理你有關python的任務和跟python無關的任務
conda使用了一個新的包格式,你不能交替使用pip 和conda。由於pip不能安裝和解析conda的包格式。你可使用兩個工具 可是他們是不能交互的。
另外,conda環境的啓動命令也在這裏記錄一下:orm
啓動source:htm
activate xxx
關閉source:
deactivate
更新:
conda env update -f environment.yml 更新配置文件