mirror of
https://github.com/sunnypilot/sunnypilot.git
synced 2026-02-18 21:14:01 +08:00
macOS: Fix missing pip command issue. (#22924)
* Fixed missing pip command issue.
* add path to openpilot_env.sh for mac
old-commit-hash: a87190342b
This commit is contained in:
@@ -61,6 +61,7 @@ fi
|
||||
|
||||
# install python
|
||||
PYENV_PYTHON_VERSION=$(cat $OP_ROOT/.python-version)
|
||||
PATH=$HOME/.pyenv/bin:$HOME/.pyenv/shims:$PATH
|
||||
pyenv install -s ${PYENV_PYTHON_VERSION}
|
||||
pyenv rehash
|
||||
eval "$(pyenv init -)"
|
||||
|
||||
@@ -1,16 +1,16 @@
|
||||
if [ -z "$OPENPILOT_ENV" ]; then
|
||||
export PYTHONPATH="$HOME/openpilot:$PYTHONPATH"
|
||||
export PATH="$HOME/.pyenv/bin:$PATH"
|
||||
|
||||
# Pyenv suggests we place the below two lines in .profile before we source
|
||||
# .bashrc, but there is no simple way to guarantee we do this correctly
|
||||
# programmatically across heterogeneous systems. For end-user convenience,
|
||||
# we add the lines here as a workaround.
|
||||
# https://github.com/pyenv/pyenv/issues/1906
|
||||
export PYENV_ROOT="$HOME/.pyenv"
|
||||
|
||||
unamestr=`uname`
|
||||
if [[ "$unamestr" == 'Linux' ]]; then
|
||||
export PATH="$HOME/.pyenv/bin:$PATH"
|
||||
|
||||
# Pyenv suggests we place the below two lines in .profile before we source
|
||||
# .bashrc, but there is no simple way to guarantee we do this correctly
|
||||
# programmatically across heterogeneous systems. For end-user convenience,
|
||||
# we add the lines here as a workaround.
|
||||
# https://github.com/pyenv/pyenv/issues/1906
|
||||
export PYENV_ROOT="$HOME/.pyenv"
|
||||
eval "$(pyenv init --path)"
|
||||
|
||||
eval "$(pyenv virtualenv-init -)"
|
||||
|
||||
Reference in New Issue
Block a user