推荐学习书目
Learn Python the Hard Way
Python Sites
PyPI - Python Package Index
http://diveintopython.org/toc/index.html
Pocoo
值得关注的项目
PyPy
Celery
Jinja2
Read the Docs
gevent
pyenv
virtualenv
Stackless Python
Beautiful Soup
结巴中文分词
Green Unicorn
Sentry
Shovel
Pyflakes
pytest
Python 编程
pep8 Checker
Styles
PEP 8
Google Python Style Guide
Code Style from The Hitchhiker's Guide
lululau
V2EX  ›  Python

Homebrew 安装的 Python 能 mount 到 pyenv 里一起管理吗

  •  
  •   lululau · Sep 30, 2018 · 1781 views
    This topic created in 2782 days ago, the information mentioned may be changed or developed.

    Homebrew 安装的一些软件依赖 Python2 & 3,所以 Homebrew 安装了 Python2 & 3,这两个不能删;我不是专门做 Python 开发的,不想再安装别的拷贝了,又想用 pyenv 切换 2/3 的版本,这个有办法吗?

    2 replies    2019-04-02 10:05:32 +08:00
    filosfino
        1
    filosfino  
       Oct 1, 2018
    mark,我是 brew 的归 brew 管,自己在 pyenv 又装了 N 个版本,各个项目 pyenv local 设置好
    lululau
        2
    lululau  
    OP
       Apr 2, 2019
    #!/usr/bin/env zsh

    mkdir -p ~/.pyenv/versions
    ln -nfs /usr/local/Cellar/python@2/2*(On[1]) ~/.pyenv/versions/
    ln -nfs /usr/local/Cellar/python@2/2*(On[1]) ~/.pyenv/versions/2
    ln -nfs /usr/local/Cellar/python/3*(On[1]) ~/.pyenv/versions/
    ln -nfs /usr/local/Cellar/python/3*(On[1]) ~/.pyenv/versions/3
    cd ~/.pyenv/versions/3/bin
    cp -Rf python3 python
    cp -Rf pip3 pip
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   2794 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 29ms · UTC 15:44 · PVG 23:44 · LAX 08:44 · JFK 11:44
    ♥ Do have faith in what you're doing.