curl https://mirrors.shuosc.cn/vscode/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] https://mirrors.shuosc.cn/vscode/repos/vscode stable main" > /etc/apt/sources.list.d/vscode.list'
sudo apt-get update
sudo apt-get install code # or code-insiders
sudo rpm --import https://mirrors.shuosc.cn/vscode/keys/microsoft.asc
sudo sh -c 'echo -e "[code]\nname=Visual Studio Code\nbaseurl=https://mirrors.shuosc.cn/vscode/yumrepos/vscode\nenabled=1\ngpgcheck=1\ngpgkey=https://mirrors.shuosc.cn/vscode/keys/microsoft.asc" > /etc/yum.repos.d/vscode.repo'
# 使用dnf管理工具的执行下面命令安装vscode
dnf check-update
sudo dnf install code
# 使用yum管理工具的执行下面命令安装vscode
yum check-update
sudo yum install code
sudo rpm --import https://mirrors.shuosc.cn/vscode/keys/microsoft.asc
sudo sh -c 'echo -e "[code]\nname=Visual Studio Code\nbaseurl=https://mirrors.shuosc.cn/vscode/yumrepos/vscode\nenabled=1\ntype=rpm-md\ngpgcheck=1\ngpgkey=https://mirrors.shuosc.cn/vscode/keys/microsoft.asc" > /etc/zypp/repos.d/vscode.repo'
sudo zypper refresh
sudo zypper install code