[TOC]
环境
Ubuntu 版本信息:
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 20.04.3 LTS
Release: 20.04
Codename: focal
安装 Visual Studio Code
访问 Visual Studio Code 官网,下载安装包:
下载完成,进入安装所在的目录,使用 sudo apt install ./<file>.deb
命令格式安装 Visual Studio Code(第 1 行):
$ sudo apt install ./code_1.66.2-1649664567_amd64.deb
[sudo] password for mk:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'code' instead of './code_1.66.2-1649664567_amd64.deb'
The following packages were automatically installed and are no longer required:
ca-certificates-mono cli-common libgdiplus libglib2.0-cil libgtk2.0-cil
libmono-addins-gui0.2-cil libmono-addins0.2-cil
libmono-btls-interface4.0-cil libmono-cairo4.0-cil libmono-corlib4.5-cil
libmono-i18n-west4.0-cil libmono-i18n4.0-cil libmono-posix4.0-cil
libmono-security4.0-cil libmono-sharpzip4.84-cil
libmono-system-configuration4.0-cil libmono-system-core4.0-cil
libmono-system-drawing4.0-cil libmono-system-numerics4.0-cil
libmono-system-security4.0-cil libmono-system-xml4.0-cil
libmono-system4.0-cil mono-4.0-gac mono-gac mono-runtime mono-runtime-common
mono-runtime-sgen
Use 'sudo apt autoremove' to remove them.
The following NEW packages will be installed:
code
0 upgraded, 1 newly installed, 0 to remove and 95 not upgraded.
Need to get 0 B/82.7 MB of archives.
After this operation, 346 MB of additional disk space will be used.
Get:1 /home/mk/Downloads/code_1.66.2-1649664567_amd64.deb code amd64 1.66.2-1649664567 [82.7 MB]
Selecting previously unselected package code.
(Reading database ... 167020 files and directories currently installed.)
Preparing to unpack .../code_1.66.2-1649664567_amd64.deb ...
Unpacking code (1.66.2-1649664567) ...
Setting up code (1.66.2-1649664567) ...
Processing triggers for mime-support (3.64ubuntu1) ...
Processing triggers for gnome-menus (3.36.0-1ubuntu1) ...
Processing triggers for shared-mime-info (1.15-1) ...
Processing triggers for desktop-file-utils (0.24-1ubuntu3) ...
安装完成,可以在应用中心找到 Visual Studio Code: