【已解决】[email protected]: Permission denied (publickey).处理git 无权限访问问题

解决思路

分析

[email protected]: Permission denied (publickey).

fatal: Could not read from remote repository.

意译:权限拒绝(公开密钥),后果:无法读远程仓库。

人话:GitHub设置里面的公钥没有配置或者和本地的私钥不匹配。

处理方案及步骤

1、打开命令提示符

输入如下指令,生成SSH KEY

bash 复制代码
ssh-keygen -t rsa -C "[email protected]"

一路确定

2、复制公钥内容

根据公钥地址找到公钥,复制公钥。

3、设置公钥

GitHub个人账户【setting】设置【SSH KEY】

4、clone仓库代码
bash 复制代码
git clone [email protected]:xxx/xxx.git

文章参考:跳转

相关推荐
HahaMonsters14 分钟前
Git 中回退版本后修改并提交
git
大小科圣15 分钟前
git版本控制器
git
掉头发的王富贵1 小时前
受不了github的网络限制了,我开源了一个图床工具 gitee-spring-boot-starter
spring boot·后端·github
uhakadotcom2 小时前
Turborepo:提升Monorepo项目构建效率的利器
后端·面试·github
uhakadotcom2 小时前
Python 列表添加元素:`append()` 和 `extend()` 的区别
后端·面试·github
ZZQ-ZZQ4 小时前
版本控制工具——Git
git·gitee·github·版本控制·gitea
xinxiyinhe12 小时前
Github最新AI工具汇总2025年4月份第2周
人工智能·github
lzq60314 小时前
5分钟上手GitHub Copilot:AI编程助手实战指南
github·copilot·ai编程
前端啊龙15 小时前
Git vs SVN 核心区别
git·svn
CyberSecurity_zhang15 小时前
Git工作流、命令汇总
服务器·git