add debian pip guide
This commit is contained in:
36
debian-python3-pip/README.md
Normal file
36
debian-python3-pip/README.md
Normal file
@@ -0,0 +1,36 @@
|
||||
- Debian 계열 distro는 공히 모두 해당된다.
|
||||
- Ubuntu
|
||||
- Linux Mint
|
||||
- Kali Linux
|
||||
|
||||
```sh
|
||||
sudo apt update && sudo apt install -y python3-dev python3-venv
|
||||
|
||||
# 현 상태 점검
|
||||
which python pip python3 pip3
|
||||
/usr/bin/python3 # 씨스템 파이썬
|
||||
|
||||
# 홈폴더로 간다
|
||||
cd ~
|
||||
|
||||
# .을 앞에 붙여야 리눅스 숨김폴더라 눈에 안거슬리고 실제로 옮기거나 삭제할 리스크도 줄어든다
|
||||
python3 -m venv .venv
|
||||
|
||||
echo -e '\nexport PATH="$HOME/.venv/bin:$PATH"\n' >> .bashrc
|
||||
|
||||
# 눈으로 확인
|
||||
tail .bashrc
|
||||
...
|
||||
export PATH="$HOME/.venv/bin:$PATH"
|
||||
|
||||
# .bashrc 반영
|
||||
bash
|
||||
|
||||
# 잘된 상태
|
||||
which python pip
|
||||
/home/.../.venv/bin/python
|
||||
/home/.../.venv/bin/pip
|
||||
|
||||
# 앞으로 pip을 쓰면 모두 .venv에 깔리지만 내가 신경쓸 것은 없다
|
||||
pip install streamlit
|
||||
```
|
||||
Reference in New Issue
Block a user