--- title: VS Code Installation on Ubuntu 18.04 tags: VSCode # type: slide --- # VS Code Installation on Ubuntu 18.04 1. The following scripts can be written to a bash file named "vscode_install.sh". ```bash= YELLOW="\e[1;33m" ENDCOLOR="\e[m" echo -e "${YELLOW}[Begin to install VS CODE]${ENDCOLOR}" echo -e "${YELLOW}[Add key and source list of vscode to apt]${ENDCOLOR}" curl https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor > microsoft.gpg sudo mv microsoft.gpg /etc/apt/trusted.gpg.d/microsoft.gpg sudo sh -c 'echo "deb [arch=amd64] http://packages.microsoft.com/repos/vscode stable main" > /etc/apt/sources.list.d/vs-code.list' echo -e "${YELLOW}[Update the package lists]${ENDCOLOR}" sudo apt update -y echo -e "${YELLOW}[Install the package]${ENDCOLOR}" sudo apt install code echo -e "${YELLOW}[Installation completed]${ENDCOLOR}" ``` 2. Then execute the following command on the terminal. ```bash= bash ./vscode_install.sh ```