WSL Ubuntu에 Python 설치

2023. 11. 21. 17:37서버 프로그래밍

Ubuntu에 Python 버전이 여러개 설치 되어 있을 경우, 처리하는 방법

https://seongkyun.github.io/others/2019/05/09/ubuntu_python/

 

우분투에서 파이썬 버전 변경하기 · Seongkyun Han's blog

또한 alternative는 python뿐만이 아니라 java와 같은 다양한 프로그램의 버전을 관리하는데 사용이 가능하다.

seongkyun.github.io

https://iohk.zendesk.com/hc/en-us/articles/16724475448473-Install-Python-3-11-on-ubuntu

https://roeldowney.tistory.com/522

 

[Python] 우분투(Ubuntu)에서 pip & pip3 설치(install) 방법

우분투(Ubuntu)에서 pip & pip3 설치(install) 방법 pip이란 python으로 작성된 패키지의 설치 및 관리를 해주는 프로그램이다. pip을 이용하면 의존성 문제를 자동적으로 해결해주기 때문에 편리하다. 만

roeldowney.tistory.com

 

Notice you're running python3 -m pip install --upgrade pip before running update-alternatives.
This means you upgraded pip to the latest 23.2.1 for Python 3.10, but for Python 3.11 the apt-provided pip 22.0.2 is still used.

https://github.com/giampaolo/psutil/issues/2301

 

[Ubuntu] ERROR: Failed building wheel for psutil · Issue #2301 · giampaolo/psutil

Summary OS: { Ubuntu 22.02 } Architecture: { ARM64 } Psutil version: { pip3 show psutil: WARNING: Package(s) not found: psutil } Python version: { 3.11.5 } Type: { installation } Description I am b...

github.com

 

The reason might be that you saved the file on Windows, with CR LF as the line ending (\r\n).

Run the following command in your terminal:

sed -i -e 's/\r$//' scriptname.sh

(Of course, change scriptname.sh to your file name)

The command will replace those CR characters with nothing, which will leave these lines with LF (\n) as the ending, and Bash will be able to read and execute the file by running

./scriptname.sh

https://stackoverflow.com/questions/14219092/bash-script-bin-bashm-bad-interpreter-no-such-file-or-directory

 

Bash script – "/bin/bash^M: bad interpreter: No such file or directory"

I'm using this tutorial to learn bash scripts to automate a few tasks for me. I'm connecting to a server using putty. The script, located in .../Documents/LOG, is: #!/bin/bash # My first script echo &

stackoverflow.com