首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
社区首页 >问答首页 >如何解决这个与gh相关的更新键环问题?

如何解决这个与gh相关的更新键环问题?
EN

Ask Ubuntu用户
提问于 2022-10-11 23:48:18
回答 1查看 282关注 0票数 0

这个错误与gh (github命令行)相关联。

代码语言:javascript
运行
AI代码解释
复制
$ sudo apt update
...                                                                                                            
Get:3 https://cli.github.com/packages stable InRelease [3,917 B]                                                                                                                     
Err:3 https://cli.github.com/packages stable InRelease                                                                                        
  The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 23F3D4EA75716059
...
Fetched 338 kB in 2s (154 kB/s)    
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
All packages are up to date.
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.github.com/packages stable InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 23F3D4EA75716059
W: Failed to fetch https://cli.github.com/packages/dists/stable/InRelease  The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 23F3D4EA75716059
W: Some index files failed to download. They have been ignored, or old ones used instead.

它的安装命令是:

代码语言:javascript
运行
AI代码解释
复制
type -p curl >/dev/null || sudo apt install curl -y
curl -fsSL https://cli.github.com/packages/githubcli-archive-keyring.gpg | sudo dd of=/usr/share/keyrings/githubcli-archive-keyring.gpg \
&& sudo chmod go+r /usr/share/keyrings/githubcli-archive-keyring.gpg \
&& echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/githubcli-archive-keyring.gpg] https://cli.github.com/packages stable main" | sudo tee /etc/apt/sources.list.d/github-cli.list > /dev/null \
&& sudo apt update \
&& sudo apt install gh -y

我认为这意味着一个与/usr/share/keyrings/githubcli-archive-keyring.gpg.有关的问题我已经卸载了gh

如何在sudo apt update期间消除此问题?

EN

回答 1

Ask Ubuntu用户

回答已采纳

发布于 2022-10-12 00:32:44

在@muru注释之后,我删除了/etc/apt/sources.list.d/github-cli.list/etc/apt/sources.list.d/github-cli.list.distUpgrade/etc/apt/sources.list.d/github-cli.list.save文件。问题解决了。

Sidenote:从Ubuntu20.04升级到22.04之后,我还在/etc/apt/sources.list.d中找到了许多Ubuntu20.04文件(即Ubuntu20.04)。我也删除了这些旧文件。

票数 0
EN
页面原文内容由Ask Ubuntu提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://askubuntu.com/questions/1435010

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档
查看详情【社区公告】 技术创作特训营有奖征文