简体   繁体   中英

Cannot activate virtual environment on Linux (Docker Quickstart Terminal virtual machine)

I am making some experiments with docker, using the Docker Quickstart Terminal virtual machine, on Windows 10 home.

I am following the steps listed in this tutorial to create a virtual environment.

I manage to create the environment, but then I cannot activate it.

Creating the virtual environment:

Tommaso@N552VW-Tommaso MINGW64 ~/Django rest framework/Udemy Django/TDD-Python-Django/recipe-app-api (main)

$ virtualenv met6

Using base prefix 'c:\\applicazioni_tommaso\\phyton'
New python executable in C:\Users\Tommaso\DJANGO~1\UDEMYD~1\TDD-PY~1\RECIPE~1\met6\Scripts\python.exe
Installing setuptools, pip, wheel...
done.

Activating the virtual environment

Tommaso@N552VW-Tommaso MINGW64 ~/Django rest framework/Udemy Django/TDD-Python-Django/recipe-app-api (main)

$ source met6/bin/activate

bash: met6/bin/activate: No such file or directory

Why does not it find the virtual environment I just created? I am following the tutorial step by step, what am I doing wrong?

在此处输入图片说明

you could try using source $(pwd)/met6/bin/activate
mingw has some problems with whitespaces in directorys as far as i know, possible rename the directorys before trying it 'Django rest framework'

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM