git clone问题
中秋节回来上班 竟然忘记带电脑了  ̄□ ̄||还好同事有备用电脑,这要是回去拿估计上午都不用干什么了,用同事电脑当然需要安装环境,下面说一下git上遇到的问题吧
(1)首先我尝试用https方式克隆代码,但是遇到如下错误
remote: HTTP Basic: Access denied fatal: Authentication failed for。。。
经过一番搜索大体意思是:
git config --system --unset credential.helper
然后再更新用户名 邮箱 密码等,但是网上说的这些我这都不好用(如果哪位大神指导请指教)
经过再次搜索发现如下方法解决了https方式克隆代码的问题:
git clone http://账号:密码@git.xx.xx.com.cn/xx/xx.git
(2)我又尝试了一下ssh方式克隆代码
首先查看是否有生成ssh
$ cd ~/.ssh
$ ls
authorized_keys2 id_dsa known_hosts config id_dsa.pub
发现已经生成过ssh,如果想用自己的git邮箱生成ssh key会提示覆盖,直接覆盖即可当然也可以删除掉已有的.ssh文件
$ ssh-keygen -t rsa -C "your_email@youremail.com" Creates a new ssh key using the provided email # Generating public/private rsa key pair. Enter file in which to save the key (/home/you/.ssh/id_rsa):
按照提示操作即可,查看公钥
cat ~/.ssh/id_rsa.pub
然后把key直接粘贴到git上即可
git clone问题的更多相关文章
- git clone出现的error: The requested URL returned error: 401 Unauthorized
error: The requested URL returned error: 401 Unauthorized while accessing https://git.oschina.net/.. ...
- git clone Linux 源码并切换TAG
想从github上下载一个特定TAG分支来查看代码,按照先git clone后git checkout的方式,提示说有文件没有提交.因为只查看不编译运行,所以这些关系不大的文件采取删除或者重新命名后提 ...
- git clone时,报403错误,完美解决方案
首先命令行操作结果如下: root@zhiren-PowerEdge-T110-II:/zrun# git clone https://git.coding.net/xxxxxxxx/xxxx.git ...
- git clone error: RPC failed; result=22, HTTP code = 502
http://www.jianshu.com/p/645d3fe4e028 git克隆的工程太大用https的方式会有如下问题 hbl:tmp hubert$ git clone https://gi ...
- git clone带用户名和密码的方式
git clone http://username:password@127.0.0.1/res/res.git
- git clone错误
git clone错误 Initialized empty Git repository in ***/.git/ error: The requested URL returned error: 4 ...
- git clone google代码库
git clone https://chromium.googlesource.com/chromium/src 发现有将近7G,但是速度太慢,老是失败,提示信息先后是"The remot ...
- [译]git clone
git clone git clone命令copy一个已经存在的Git仓储. git clone有点像svn的checkout, 他的不同之处是这个copy也是一个完整的仓储-它有自己的历史纪录, 能 ...
- git clone
raw text for ssh: git@github.com:TommyU/avbot_config.git git command on linux: git clone git://githu ...
- 使用git建立远程仓库,让别人git clone下来
首先, 如果你的ssh没有安装的话,要安装ssh服务端.ubuntu是很简单 sudo apt-get install openssh-server 1,建立你的git 目录. ourunix@ubu ...
随机推荐
- iOS 集成React Native到现有iOS应用(Ficow本人实测,Xcode 8.3,iOS 10.3)
详细操作步骤,请 参考官方文档 或者翻译文档 ! 我补充一些必要的注意事项: 1.引入React.a文件.配置User Header Search Paths 引入React.a文件(点击+可以看到 ...
- UVA 11149 Power of Matrix 构造矩阵
题目大意:意思就是让求A(A是矩阵)+A2+A3+A4+A5+A6+······+AK,其中矩阵范围n<=40,k<=1000000. 解题思路:由于k的取值范围很大,所以很自然地想到了二 ...
- 51nod1127 最短的包含字符串 尺取法
Bryce1010模板 #include <bits/stdc++.h> using namespace std; typedef long long LL; map<char,LL ...
- KMP HDOJ 4300 Clairewd's message
题目传送门 题意:完全不懂,最后还是看题解才理解了.第一行字符串是密文变成明文的规则,比如第二个样例:“qwertyuiopasdfghjklzxcvbnm”,‘q'对应的明文为’a','w'对应'b ...
- 解题报告:hdu 2073 无限的路
题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=2073 Problem Description 甜甜从小就喜欢画图画,最近他买了一支智能画笔,由于刚刚接 ...
- 在Eclipse+ADT中开发Android系统的内置应用
转自: http://www.iteye.com/topic/1050439 在Eclipse+ADT中开发Android系统的内置应用 Android系统内置有:Browser(浏览器).Mms( ...
- dotnet cors 跨域问题
研究了一整子的.net core框架,感觉挺好用的,可以用在实际项目中,前端avalon框架也在研究: 问题:跨域,相比原来的跨域解决方案,还是有不小的变化的,原来的.net api 只需要在WebA ...
- Android EditText 输入金额(小数点后两位)
EditText edit = new EditText(context); InputType.TYPE_NUMBER_FLAG_DECIMAL //小数点型 InputType.TYPE_CLAS ...
- 掌握Spark机器学习库-05-spark中矩阵与向量的使用
1)介绍 矩阵: Matrix,看做二维表,基本运算(+,-,*,T) 向量: Vectors,方向和大小,基本运算,范数 2)spark中向量的使用(主要使用breeze.linalg) 3)spa ...
- cookie设置和读取以及获取超链接参数
function setCookie(c_name, value, expiredays) { var exdate = new Date() exdate.setDate(exdate.getDat ...