Taking advantage of the weekend, I installed my old computer at home as an ubuntu system. Install Anaconda3 and VSCode today and record it.
sudo dpkg -i code_1.24.1-1528912196_amd64.deb
Download address: 1. Download from the official website. 2. Download from Tsinghua source. The second method downloads faster.
Tsinghua University source address: https://mirrors.tuna.tsinghua.edu.cn/anaconda/archive/
Version selection: I downloaded anaconda3-5.3.1 corresponding to python3.7
yes
, then press Enter, enter to read the registration information, until the next place where you need to enter yes
yes
yes
You can refer to my previous tweets for this part.
After configuration, you can write Python in VSCode of ubuntu
At this point, you can write and run python programs in VSCode, but you cannot use the pip and conda commands in the terminal because the environment variables are not modified.
Please install Vim before proceeding with this step. Installation method:
sudo apt-get install vim
First use Vim to open the file, enter the following command in the terminal
vim ~/.bashrc
Then press a
to enter edit mode, add at the end
export PATH=~/anaconda3/bin:$PATH
After editing, press ESC
, enter :wq
to save and exit.
Finally, restart the environment variables.
source ~/.bashrc
Recommended Posts