我正在使用Ubuntu 16.04并且我已按照说明Uninstalling the Heroku CLI进行操作。
sudo apt-get remove heroku
sudo apt-key del <Heroku's key from 'apt-key list'>
由于找不到,我没有卸载heroku-toolbelt
个包。
/etc/apt/sources.list.d/heroku.list
也不存在。
当我执行后续sudo apt update
和sudo apt dist-upgrade
时会出现问题。
Err:7 https://cli-assets.heroku.com/branches/stable/apt ./ InRelease
The following signatures couldn't be verified because the public key is not available: NO_PUBKEY C927EBE00F1B0520
...
...
...
W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: https://cli-assets.heroku.com/branches/stable/apt ./ InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY C927EBE00F1B0520
W: Failed to fetch https://cli-assets.heroku.com/branches/stable/apt/./InRelease The following signatures couldn't be verified because the public key is not available: NO_PUBKEY C927EBE00F1B0520
W: Some index files failed to download. They have been ignored, or old ones used instead.
我猜apt-key del
打破了apt,但我想彻底卸载Heroku-CLI(包括密钥),因为我不再需要它。
答案 0 :(得分:1)
运行
sudo add-apt-repository -r "deb https://cli-assets.heroku.com/branches/stable/apt ./"
解决了这个问题。