最近我注意到在运行apt时出现了一些问题,系统会警告我密钥环已经过时。
这并不妨碍我进行更新,但在更新系统时,我宁愿不见到这个。未来我们应该如何存储可信的 GPG 密钥?
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
8 packages can be upgraded. Run 'apt list --upgradable' to see them.
W: https://packages.microsoft.com/repos/edge/dists/stable/InRelease: Key is stored in legacy trusted.gpg keyring (/etc/apt/trusted.gpg), see the DEPRECATION section in apt-key(8) for details.
W: https://download.sublimetext.com/apt/stable/InRelease: Key is stored in legacy trusted.gpg keyring (/etc/apt/trusted.gpg), see the DEPRECATION section in apt-key(8) for details.
这并不妨碍我进行更新,但在更新系统时,我宁愿不见到这个。未来我们应该如何存储可信的 GPG 密钥?
sudo apt-key del <last 8 chars from sudo apt-key list | grep -i -C 5 <pgk> >
,似乎删除包和源文件grep <pkg> /etc/apt/sources.list.d/*
并重新安装起作用了。apt purge <pkg>
可能会删除源文件,但也可能同时删除配置文件。 - alchemy