1

I want to make shell which does a few things in a row like.

pipenv shell
export PYTHONPATH="/MyFunction/:$PYTHONPATH"
python manage.py runserver 8001

However pipenv shell once works, export and python manage.py doesn't work on pipenv shell

Is there any good way to set one-stop script?

whitebear
  • 11,200
  • 24
  • 114
  • 237
  • `pipenv shell` starts a new shell, blocking the rest of your script until that shell exits. Do you want the `export` to happen in *that* shell, or in your current shell once `pipenv shell` completes? – chepner Jan 31 '22 at 17:18
  • I suspect you want something like `pipenv run manage.py runserver 8001`, with whatever you have in `/MyFunction` being installed in the virtual environment managed by `pipenv`. – chepner Jan 31 '22 at 17:20
  • Does this answer your question? [bash script starting new shell and continuing to run commands](https://stackoverflow.com/questions/48056606/bash-script-starting-new-shell-and-continuing-to-run-commands) – Jason Harrison Feb 24 '22 at 20:36

0 Answers0