How to change pip3 command to be pip?

前端 未结 9 2501
梦毁少年i
梦毁少年i 2020-12-04 23:33

I uninstalled pip, and I installed pip3 instead. Now, I want to use pip3 by typing pip only. The reason is I am used to t

9条回答
  •  难免孤独
    2020-12-05 00:09

    you can either add alias to your ~/.bashrc

    alias pip=pip3
    

    or add to your $PATH symlink named pip pointing to pip3 binary

    (btw, this even though concerning pip isn't really python related question, so you should retag it)

    Update: July 2020

    If there is no ~/.bashrc in your home directory on macOS, inputting

    alias pip=pip3
    

    in your ~/.zprofile file has the same effect,

提交回复
热议问题