sudo apt-get upgrade - 软件包 sublime-text 需要重新安装吗?

sudo apt-get upgrade - 软件包 sublime-text 需要重新安装吗?

我该如何修复下面的 sublime-text 错误:

$ sudo apt-get upgrade
Reading package lists... Done
Building dependency tree       
Reading state information... Done

错误:

E: The package sublime-text needs to be reinstalled, but I can't find an archive for it.

即使我尝试删除它,我仍然遇到同样的错误:

$ sudo apt-get remove sublime-text
Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: The package sublime-text needs to be reinstalled, but I can't find an archive for it.

有任何想法吗?

答案1

要消除此错误,请在终端中逐个输入以下命令:-

sudo apt-get purge sublime-text

sudo apt-get autoremove

sudo apt-get update

此后sudo apt-get upgrade将正常工作并且不会显示错误。

安装Sublime Text,从以下网址下载适用于 Ubuntu/Debian 的 .deb 软件包这里.然后从该 .deb 包安装 Sublime Text,或者使用软件包或者GDebi 软件包安装程序(受到推崇的)。

相关内容