-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpython_envs
More file actions
53 lines (49 loc) · 2.31 KB
/
python_envs
File metadata and controls
53 lines (49 loc) · 2.31 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
846 cd Desktop
847 cd Tech_Work
848 cd install
849 cd python_envs
850 python3 --version
851 pwd
852 mkdir -p welcome
853 pwd
854 pip3 install virtualenv
855 cd ..
856 virtualenv -p python3 python_envs
857 source python_envs/bin/activate
(python_envs) welcome@welcomes-MacBook-Pro install %
1. Install Python3
Install Python3 and then check to make sure the python version is 3+
% brew install python3
% python3 --version
Python 3.8.10
2. Open a Terminal window and execute below command.
mkdir -p ~/install
3. Create a working directory here called airflow-tutorial by executing below command.
mkdir -p ~/install/airflow-tutorial
4. Run below command to install python virtual environment.
pip3 install virtualenv
Output:
Collecting virtualenv
Downloading virtualenv-20.13.1-py2.py3-none-any.whl (8.6 MB)
|████████████████████████████████| 8.6 MB 2.2 MB/s
Requirement already satisfied: six<2,>=1.9.0 in /usr/local/lib/python3.8/site-packages (from virtualenv) (1.15.0)
Collecting filelock<4,>=3.2
Downloading filelock-3.6.0-py3-none-any.whl (10.0 kB)
Collecting distlib<1,>=0.3.1
Downloading distlib-0.3.4-py2.py3-none-any.whl (461 kB)
|████████████████████████████████| 461 kB 1.3 MB/s
Collecting platformdirs<3,>=2
Downloading platformdirs-2.5.1-py3-none-any.whl (14 kB)
Installing collected packages: platformdirs, filelock, distlib, virtualenv
Successfully installed distlib-0.3.4 filelock-3.6.0 platformdirs-2.5.1 virtualenv-20.13.1
5. Create a virtual environment.
virtualenv -p python3 ~/install/airflow-tutorial/airflow_venv
Output:
created virtual environment CPython3.8.10.final.0-64 in 789ms
creator CPython3Posix(dest=/Users/rangareddy.avula/install/airflow-tutorial/airflow_venv, clear=False, no_vcs_ignore=False, global=False)
seeder FromAppData(download=False, pip=bundle, setuptools=bundle, wheel=bundle, via=copy, app_data_dir=/Users/rangareddy.avula/Library/Application Support/virtualenv)
added seed packages: pip==22.0.3, setuptools==60.6.0, wheel==0.37.1
activators BashActivator,CShellActivator,FishActivator,NushellActivator,PowerShellActivator,PythonActivator
6. Activate the virtual environment.
source ~/install/airflow-tutorial/airflow_venv/bin/activate
Out