代码之家  ›  专栏  ›  技术社区  ›  Arunabh Das

运行python3 virtualenv时使用pip3与pip有什么区别

  •  0
  • Arunabh Das  · 技术社区  · 6 年前

    我在一个virtualenv中运行python3,我创建了如下

    ==> python3 -m venv venv
    
    ==> source venv/bin/activate
    
    ==> python
    Python 3.6.5 (default, Apr 25 2018, 14:23:58) 
    [GCC 4.2.1 Compatible Apple LLVM 9.1.0 (clang-902.0.39.1)] on darwin
    Type "help", "copyright", "credits" or "license" for more information.
    

    我的web应用程序有一个带有python包依赖项的需求文件

    使用pip3和pip安装依赖项有什么区别

    ==> pip3 install -r requirements
    

    ==> pip install -r requirements
    
    1 回复  |  直到 6 年前
        1
  •  2
  •   Easton Bornemeier    6 年前

    pip2 是蟒蛇2和 pip3 是蟒蛇3号。使用 whereis pip 命令来确定可执行文件的位置,但如果您在python3 virtualenv中, pip 当然相当于 第三点 .