以下给出vscode/vscodium的安装方法,可择一安装。
sudo rpmkeys --import https://gitlab.com/paulcarroty/vscodium-deb-rpm-repo/-/raw/master/pub.gpg
printf "[gitlab.com_paulcarroty_vscodium_repo]\nname=download.vscodium.com\nbaseurl=https://download.vscodium.com/rpms/\nenabled=1\ngpgcheck=1\nrepo_gpgcheck=1\ngpgkey=https://gitlab.com/paulcarroty/vscodium-deb-rpm-repo/-/raw/master/pub.gpg" |sudo tee -a /etc/yum.repos.d/vscodium.repo
dnf check-update
sudo dnf install codium
然后在非root用户下,从软件列表启动vscodium
到vscodium仓库https://github.com/VSCodium/vscodium/releases 下载rpm包,
如 https://github.com/VSCodium/vscodium/releases/download/1.62.3/codium-1.62.3-1637281311.el7.x86_64.rpm
使用如下命令进行本地安装
sudo dnf localinstall ./codium-1.62.3-1637281311.el7.x86_64.rpm
参考自 https://code.visualstudio.com/docs/setup/linux
sudo rpm --import https://packages.microsoft.com/keys/microsoft.asc
sudo sh -c 'echo -e "[code]\nname=Visual Studio Code\nbaseurl=https://packages.microsoft.com/yumrepos/vscode\nenabled=1\ngpgcheck=1\ngpgkey=https://packages.microsoft.com/keys/microsoft.asc" > /etc/yum.repos.d/vscode.repo'
dnf check-update
sudo dnf install code
然后在非root用户下,从软件列表启动vscode
到vscode官网 https://code.visualstudio.com/#alt-downloads 或 https://code.visualstudio.com/ 下载rpm包,
如 code-1.62.3-1637137194.el7.x86_64.rpm
使用如下命令进行安装
sudo dnf localinstall ./code-1.62.3-1637137194.el7.x86_64.rpm