尝试像这样组织我的项目:
MyProjectDir
├── .git
│ ├──
├── .gitignore
├── .venv
│ ├── .gitignore
│ ├── bin
│ ├── lib
│ └── src
├── monitor_internet_connection.py但是pipenv忽略了PIPENV_VENV_IN_PROJECT
> export PIPENV_VENV_IN_PROJECT=1
> export PIPENV_DONT_USE_PYENV=1
> pipenv --python 3.8
Virtualenv already exists!
Removing existing virtualenv…
Creating a virtualenv for this project…
Pipfile: /Users/me/Documents/Try/Python/Pipfile
Using /Users/me/.pyenv/versions/3.8.5/bin/python3.8 (3.8.5) to create virtualenv…
⠧ Creating virtual environment...created virtual environment CPython3.8.5.final.0-64 in 422ms
creator CPython3Posix(dest=/Users/me/Documents/Try/Python/.venv, clear=False, global=False)
seeder FromAppData(download=False, pip=bundle, setuptools=bundle, wheel=bundle, via=copy, app_data_dir=/Users/me/Library/Application Support/virtualenv)
added seed packages: pip==20.1.1, setuptools==49.1.0, wheel==0.34.2
activators BashActivator,CShellActivator,FishActivator,PowerShellActivator,PythonActivator,XonshActivator
✔ Successfully created virtual environment!
Virtualenv location: /Users/me/Documents/Try/Python/.venv我希望.venv位于我实际的项目目录下。怎么啦?
发布于 2021-02-08 15:07:16
pipenv将在Pipfile旁边创建其“项目本地”环境--因此请确保该环境位于正确的项目目录中
pipenv文档中隐含着Pipfile应该位于项目根目录,但我找不到明确的引用
https://stackoverflow.com/questions/66081558
复制相似问题