我能够通过HTTPS身份验证克隆此repo的副本.我做了一些提交,想要推回到GitHub服务器.在Windows 7 x64上使用Cygwin.
C:\cygwin\home\XPherior\Code\lunch_call>git push
Password:
error: The requested URL returned error: 403 while accessing https://MichaelDrog
alis@github.com/derekerdmann/lunch_call.git/info/refs
fatal: HTTP request failed
Run Code Online (Sandbox Code Playgroud)
同时使用详细模式进行设置.我还是很困惑.
C:\cygwin\home\XPherior\Code\lunch_call>set GIT_CURL_VERBOSE=1
C:\cygwin\home\XPherior\Code\lunch_call>git push
Password:
* Couldn't find host github.com in the _netrc file; using defaults
* About to connect() to github.com port 443 (#0)
* Trying 207.97.227.239... * 0x23cb740 is at send pipe head!
* Connected to github.com (207.97.227.239) port 443 (#0)
* successfully set certificate verify locations:
* CAfile: C:\Program Files (x86)\Git/bin/curl-ca-bundle.crt
CApath: none
* SSL …Run Code Online (Sandbox Code Playgroud) 如何将所有远程分支拉到我自己的存储库?
如果我输入:
git branch -a
Run Code Online (Sandbox Code Playgroud)
我得到了很长的分支列表,但如果我输入:
git branch
Run Code Online (Sandbox Code Playgroud)
我只看到其中的两个.
如何将所有分支拉入本地列表?
我知道我能做到:
git checkout --track origin/branch-name
Run Code Online (Sandbox Code Playgroud)
但是,它一次只能拉出并检出一个分支.有没有什么方法可以一次性完成所有这一切,而不需要git checkout --track origin/branch-name一遍又一遍地运行这些繁琐乏味的工作?
PS.我尝试了以下命令,没有一个命令使远程分支出现在我的git branch列表中:
git fetch --all
git remote update
git pull --all
Run Code Online (Sandbox Code Playgroud) 我一直在使用私有Gitlab实例来保存我的所有代码.但由于与我合作的大多数员工现在都有一个Github帐户,我真的很想移动并将我的Gitlab回购镜像给Github.
我的情况:
我知道--mirrorgit 中有切换,但我不确定这是如何工作的.我在网上找到的文档非常糟糕......所以如果有人可以帮助我,那就太好了.:)
我最近创建了一个 Gitlab 帐户,我想将其用作投资组合。我创建了一个Github 页面,其中包含一些内容。现在的问题是,我正在尝试将我在 Gitlab 中所做的所有项目导入到我的 Github 帐户中。我在谷歌和论坛上搜索过,有些人建议我需要制作令牌,我试过了,但没有用。
我试图通过我的个人资料附近的“+”按钮将单个 Gitlab 存储库导入我的 Github 存储库。它不适用于消息“在https://git.osl.frl/JVeenswijk/pfSense未检测到源存储库。请检查 URL 并重试”(是的,项目设置为public),我相信从中从 Gitlab 导入无法正常工作。
所以我尝试使用令牌、导入甚至通过 Github 桌面进行尝试,但这些都不适合我。我觉得很奇怪,Github 和 Gitlab 相互连接有这么大的麻烦,从我的角度来看,它们的功能几乎相同,但功能不同。
现在的问题是: