tools: configure PYTHONPATH in pipenv (#23361)

* automatically set PYTHONPATH in pipenv

* remove other place this was set
pull/23326/head
Greg Hogan 3 years ago committed by GitHub
parent 8dd8b1905b
commit 3e5a273022
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 1
      .gitignore
  2. 2
      tools/openpilot_env.sh
  3. 1
      update_requirements.sh

1
.gitignore vendored

@ -1,4 +1,5 @@
venv/ venv/
.env
.clang-format .clang-format
.DS_Store .DS_Store
.tags .tags

@ -1,6 +1,4 @@
if [ -z "$OPENPILOT_ENV" ]; then if [ -z "$OPENPILOT_ENV" ]; then
OP_ROOT="$(cd "$(dirname "${BASH_SOURCE[0]}")"/.. && pwd)"
export PYTHONPATH="$OP_ROOT:$PYTHONPATH"
export PATH="$HOME/.pyenv/bin:$PATH" export PATH="$HOME/.pyenv/bin:$PATH"
# Pyenv suggests we place the below two lines in .profile before we source # Pyenv suggests we place the below two lines in .profile before we source

@ -32,6 +32,7 @@ if [ -d "./xx" ]; then
fi fi
if [ -z "$PIPENV_SYSTEM" ]; then if [ -z "$PIPENV_SYSTEM" ]; then
echo "PYTHONPATH=${PWD}" > .env
RUN="pipenv run" RUN="pipenv run"
else else
RUN="" RUN=""

Loading…
Cancel
Save