github使用问题汇总

1. Permission denied

1.1. 问题描述

Permission denied (publickey).

fatal: Could not read from remote repository.

1.2. 解决方法

生成公钥

bash 复制代码
ssh-keygen -t ed25519 -C "your_email@example.com"

点击回车三次

bash 复制代码
Generating public/private ed25519 key pair.                                                          
Enter file in which to save the key (/home/xxx/.ssh/id_ed25519): 
Enter passphrase (empty for no passphrase):                                                          
Enter same passphrase again:     
Your identification has been saved in /home/xxx/.ssh/id_ed25519
Your public key has been saved in /home/xxx/.ssh/id_ed25519.pub                             
The key fingerprint is:
SHA256:+plNIhibsYxRgWtH+mC08HoXLp62ylAB2YQgcZaddBk haitao.xue@nio.com                               
The key's randomart image is:
+--[ED25519 256]--+
|**+=o.Eo         |
|=+= +o.          |
| +.=.            |
|  Ooo            |
| +o=o.  S        |
|..o++B .         |
|.o.+* o . .      |
|o +    o *       |
|.+..    + .      |
+----[SHA256]-----+

读取公钥

bash 复制代码
cat ~/.ssh/id_ed25519.pub

把公钥填入到github中

参考文献

Generating a new SSH key and adding it to the ssh-agent - GitHub Docs

相关推荐
wflynn22 分钟前
GitHub 日榜趋势速报 | 2026-11-17
开源·github
敢敢是只喵i15 小时前
OpenAPI 里有两个 quantity,审批规则到底在比哪个?
github
七分辣度15 小时前
GitHub/Git 常用命令及使用场景
git·github
dong_junshuai15 小时前
每天一个开源项目#160 LoopForge:把Agent交付拆成可退回的验收流程
github
Allen366817 小时前
给博客和秘书加上 HTTPS 之后的一点记录
github
laoyeye83118 小时前
手写 vLLM 分页 KV Cache(二):深入物理块分配、Block Table 与 Slot Mapping
github
Summer-Bright20 小时前
企业落地智能体,供应链签名还是空白:1862 个 MCP 服务器无认证裸奔
服务器·人工智能·github·mcp
一条Go20 小时前
Pod 终端与日志:为什么浏览器建连要先换一张 60 秒的票
后端·架构·github
一条Go20 小时前
开源新生代雷达 · 第 14 期
github
徐小夕1 天前
万字拆解:零向量库、无模型微调,SAG2 凭什么刷新多跳问答 SOTA
前端·vue.js·github