macports didn't place python_select in /opt/local/bin

前端 未结 2 748
谎友^
谎友^ 2020-12-05 05:22

I\'ve uninstalled and reinstalled python_select using MacPorts and yet it won\'t show up in /opt/local/bin. Consequently, I get a \"command not found\" error when attempting

相关标签:
2条回答
  • 2020-12-05 05:37
    sudo port select --set python python25
    

    This will set the Python alias (/opt/local/bin/python) to python25

    If you're not sure which versions of Python you have to select from, you can use:

    $ port select --list python
    Available versions for python:
        none
        python24
        python25-apple
        python26
        python26-apple
        python27 (active)
    

    This shows you that python27 is selected, and that versions 25 & 26 have Apple specific versions (these are distributed with OS X).

    0 讨论(0)
  • 2020-12-05 05:43

    It seems that python_select has been deprecated:

    "python_select" (and other standalone *_select scripts) is gone.

    Use "sudo port select python python26" etc.

    0 讨论(0)
提交回复
热议问题