我从一个网页上复制并粘贴了一个git克隆命令:https://fedorahosted.org/ibus-typing-booster/

我得到了这个:

user@host> git clone ​​http://git.fedorahosted.org/git/ibus-typing-booster.git

Cloning into 'ibus-typing-booster'...
fatal: I don't handle protocol '​​http'

当前回答

请不要从剪贴板上复制。 只需从浏览器的位置/地址栏复制url。

其他回答

我复制粘贴了整行git克隆http://....

git克隆和http://..之间的字符。看起来像一个空格,但它是一个特殊的Unicode字符!

简单回答:在移除这个字符并进入一个真实的空间后,它就起作用了!

对于喜欢细节的人:我看到了两种显示ascii字符和特殊unicode字符的方法

Way1: Python

这是真正的台词:

vi t.txt # copy+paste the line
python
open('t.txt').read()
git clone \xe2\x80\x8b\xe2\x80\x8bhttp://...

Way2:更少的

vi t.txt # copy+paste the line
LESSCHARSET=ascii less vi.txt

如果它看起来像git clone <E2><80><8B><E2><80><8B>http://,,那么你复制+粘贴special-unicode-characters。

克隆如下:

git clone https://github.com/zendframework/ZendSkeletonApplication.git

给错误:

Cloning into 'ZendSkeletonApplication'...
fatal: I don't handle protocol 'https'

修改为:

git clone https://github.com/zendframework/ZendSkeletonApplication

工作完美,或者你可以只是复制url。 我使用的是操作系统windows 10和giitbash。

如果你使用的是Windows,使用“url”语音标记来打开和关闭你的url Git克隆“your-url-here”

我的解决方案:

类型:git克隆。 复制存储库url,并粘贴后的git克隆。 将光标移动到git clone和https://..之间的位置。 如果git clone和https://..之间有空格,删除空格。直到 有git clonehttps://… 重新添加空格并按“Enter”。

请检查您所粘贴的URL,克隆后需要额外的h。

所以你要么粘贴完整的git克隆http://<URL>.git,要么只是在git存储库URL前删除额外的字母。