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

相关推荐
酉鬼女又兒3 小时前
零基础入门 DeepSeek V4 Pro API 开发:从环境搭建、消息格式规范到翻译函数实战、少样本提示、多轮对话聊天机器人与常见报错全流程详解指南
大数据·网络·数据库·人工智能·macos·机器人·github
小弥儿4 小时前
GitHub今日热榜 | 2026-07-17:教育Agent与极低量化分庭抗礼
学习·开源·github
第一程序员9 小时前
Rust trait 入门:把 AI 客户端抽象成可替换接口
python·rust·github
Jackson__9 小时前
问到你想清楚,这个 skill 专治没想明白就写代码!
前端·github·ai编程
Curvatureflight11 小时前
FastAPI WebSocket 实战:从零实现一个实时消息推送服务
github
风向决定发型d78212 小时前
Github Copilot 实战应用与效能提升指南
log4j·github·copilot
嘟嘟071715 小时前
手把手带你封装 Claude Code Skill:从会议纪要到 AI 日报,一套固定格式搞定所有自动化
github
嘟嘟071715 小时前
像水流一样——前端流式输出完整指南(3)
面试·github
半夜修仙17 小时前
Spring集成邮箱功能
java·开发语言·spring boot·spring·rabbitmq·github·maven
Esaka_Forever17 小时前
Prompting Techniques提示词工程核心知识梳理
人工智能·github