今天碰到了Git的Permission Denied问题。
在安装好git之后,我们一般会配置用户名和邮箱
git config --global user.name "zengjinlong" #--global表明本机的所有git仓库均使用该配置
git config --global user.email "zengjinlong@xunlei.com"
但是当我们克隆一个库的时候,发现不论你怎么输入密码都是说Permission Denied。
其实,这是你没有生成公钥
找到这个页面:
SSH Keys
SSH key allows you to establish a secure connection between your computer and GitLab
Before generating an SSH key, check if your system already has one by running cat ~/.ssh/id_rsa.pub If your see a long string starting with ssh-rsa or ssh-dsa, you can skip the ssh-keygen step.
To generate a new SSH key just open your terminal and use code below. The ssh-keygen command prompts you for a location and filename to store the key pair and for a password. When prompted for the location and filename you can press enter to use the default.
It is a best practice to use a password for an SSH key but it is not required and you can skip creating a password by pressing enter. Note that the password you choose here can't be altered or retrieved.
ssh-keygen -t rsa -C "$your_email"
Use the code below to show your public key.
cat ~/.ssh/id_rsa.pub
Copy-paste the key to the 'My SSH Keys' section under the 'SSH' tab in your user profile. Please copy the complete key starting with ssh- and ending with your username and host.
很简单,就是用你的邮箱生成一个公钥,然后加入到你的代码管理网站中。然后在如下页面中加入SSH Key到项目中。
SSH keys allow you to establish a secure connection between your computer and GitLab
Before you can add an SSH key you need togenerate it
然后再git clone 一次,发现可以了。好了。这个问题解决。
分享到:
相关推荐
附件是在使用Git过程中遇到的Permission Denied Publickey的问题,之前把该问题组织成一个文档了。
2、可以使用git push origin master:master推送成功,但是使用idea直接在git选项下推送还是报Permission Denied (publickey)。 可能下面提到的解决方法不是最简单的解决办法,但是我经过亲测后,能够解决上面的问题...
最近在一个基于 git 的发布系统中拉取代码,发现无法拉取最新的提交记录,通过调试和查看日志文件找到一行错误:error: cannot open .git/FETCH_HEAD: Permission denied,原因是文件权限问题导致。 问题原因 ...
第一步 重新生成ssh ssh-keygen -t rsa -C “这里需要填写邮箱。我填写的是我的绑定主邮箱。我想其他邮箱也是可以的,只不过我没有测试。” 第二步 ...最后输入ssh -T git@gitee.com 即可 作者:亦圻
问题描述: 在使用git 进行提交时, 出现上面这个报错, 导致无法提交. 报错大致意思就是创建index.lock文件失败,因为已经存在index.lock文件了. index.lock文件是在.git下面, 而.git是一般是隐藏的, 那么可以通过以下...
linux上视频压缩工具,直接解压就可以使用。压缩命令百度一下。ffmpeg -y -i $1 -f mp4 -vcodec libx264 -b 600000 -r 25 $2参数详解可以百度一下。
解决github频繁输密码问题和git@github.com:Permission denied (publickey)问题为http时,解决频繁输账名密码问题
AndroidStudio中使用Git-初级篇(一)——从github上传和下载项目(by 星空武哥)-附件资源
Permission denied (publickey). fatal: Could not read from remote repository. Please make sure you have the correct access rights and the repository exists. at org.jenkinsci.plugins.gitclient....
首先说一下网上的各种解决方案,如下: 第一种: 说让在本地生成新的公钥,然后复制到github上的设置里的 SSH keys里保存即可。 解释: 首先,这个说法没错,但是网上说的都是本地电脑用ssh方法拉不下来代码,用这个...
第一次提交,需要和远程仓库建立联系 Git remote add origin https[url] ...解决码云出现git@gitee.com: Permission denied (publickey)的问题 详细参考下述链接: https://blog.csdn.net/dyy_csdn/article/de
相关文件 (日语) 建立 ... 如果Permission denied (publickey). 发生并且尚未导入.ssh ,然后尝试使用$ git clone https://github.com/kibitan/setup_mac.git ~/setup_mac 箱 压缩工作目录(例如~
#Safely 将 Wordmove 与 www-data 一起使用 Web 服务器使用 www-data? 想要将 ssh 与 www-data 一起使用而不会让您的服务器受到攻击... 如果您收到Permission denied (publickey) ,您需要 。 #make in runnable $ e
除错如果在运行npm start时出现Permission denied错误删除node_modules rm -rf node_modules删除package.json锁定文件rm package-lock.json清除npm缓存npm cache clean --force安装依赖项npm install现在启动服务器...
为您提供syncd 代码部署工具下载,...特性:Go语言开发,编译简单、运行高效Web界面访问,交互友好权限模型灵活自由支持自定义构建支持Git仓库支持分支、Tag上线部署Hook支持,可扩展性强完善的上线工作流邮件通知机制
社区 入门 在开始之前,您需要安装...如果出现诸如Error: EACCES: permission denied, access '/usr/local/lib/node_modules' ,一起运行 sudo npm install -g parcel-bundler 或者 install yarn yarn global add pa
(use python setup.py install --user if you get a permission denied message. This does a local install for the user) 要求:Python 3,Linux 当前,GLMnet.so的签入版本针对以下配置进行编译: Linux: ...
KfMobile 为这美好的KF献上祝福! 项目简介 本项目为【为这美好的KF献上祝福!】计划第三弹,逐步为广大KFer提供适用于移动浏览器的KF反向...注:Linux下,如出现mkdir(): Permission denied的错误,替换runtime目录的
:fire: 消防电话Python 帮助程序库。 查看完整文档。...cd firecall⇒ python setup.py install :information: 如果发生Permission denied错误,您只需要使用sudo入门入门很简单: # Import firecallimpor
有关更多信息,请检查此问题: : 这个gem / npm-package允许您从Git存储库中以分散的方式安装Elm软件包,这允许: 安装效果管理器和本机软件包安装软件包的分支以测试或发布未发布的功能使用本地目录中的软件包使用...