After installing Ubuntu 20.04 using VirtualBox on Windows 10 and setting Python and pip3 etc., I will tell a story I asked a friend about a text editor such as vim.
It took a long time when I set it up to program Python, so I will focus on what was difficult to understand even if I looked it up, so I will omit a little part that comes out immediately after checking it.
There is a virtualization support function in the BIOS settings. However, since WIN10 ignores the BIOS settings and speeds up the boot, even if you press the "F2" or "DEL" key (most manufacturers can go to the BIOS screen with either of these keys), the BIOS setting screen Is not displayed. Therefore, uncheck "Enable fast startup" in the shutdown settings of "Control Panel"-> "Hardware and Sound"-> "Power Options"-> "System Settings". Then turn on Intel VT from the BIOS. You won't be able to go to the BIOS screen anymore, so you can turn fast startup back on.
This wasn't too difficult, so I'll omit it.
After starting VirtualBox, press New at the top and set it. If you do not intend to do heavy processing of memory, the official recommended value is 4GB, the hard disk is created virtually, and the file size is about 4.5GB in Ubuntu itself, so I think that it is okay to prepare 10GB or more. Local disk/user/(user name)/VirtualBox VMs/(system name)
When Ubuntu can be started, start Terminal. then,
sudo apt update
sudo apt -y upgrade
Type in. These are to update the version of Python 3 originally included in Ubuntu 20.04. After that, let's update the version of pip3 as well.
sudo apt install -y python3-pip
Now both Python3 and pip3 are in the latest version.
I introduced it to write a program, but I was using "vim". It was easy to install, but it was difficult to use, and even if I looked up the settings, I couldn't figure out why, and I just slept.
pip3 install vim //install vim
vi ~/.vimrc //open vim config file
After opening the configuration file, you can set it by entering the command to be set and then closing the configuration file. To close
ESC key
:wq //Save the entered configuration command and close the file.
Press. Here, when I typed: wq, the characters were not displayed, so I didn't know if I was typing, so I thought it would be difficult to do. The configuration command is, for example
set number
If so, the number of lines will be displayed. As shown above, you can set it like set + setting contents. I hope that you can check the settings and add them to your personal taste.
After making these settings, it's difficult to use, right? When I asked my friends, they advised me to use "nano" or to create a program with "Visual Studio Code" (hereinafter VS code) and then move it to Ubuntu. "Nano" can be used as if it were a notepad. "VS code" is created by Microsoft, but you can use MAC as well as Windows. It seems that there are many extensions for free, so I think they can be used widely (I can't talk much because I touched them lightly in class).
After all, when choosing a text editor, you should use "vim" for romance, and "nano", "VS code", etc. if you don't like troublesome settings.
Recommended Posts