加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 综合聚焦 > 服务器 > Windows > 正文

在Windows下克隆git repo时出现“错误:无法创建文件…(是一个目

发布时间:2020-12-14 02:04:48 所属栏目:Windows 来源:网络整理
导读:Z:git clone git://github.com/kennethreitz/httpbin.gitCloning into 'httpbin'...remote: Counting objects: 1073,done.remote: Compressing objects: 100% (401/401),done.remote: Total 1073 (delta 672),reused 1045 (delta 651)Receiving objects: 10
Z:&;git clone git://github.com/kennethreitz/httpbin.git
Cloning into 'httpbin'...
remote: Counting objects: 1073,done.
remote: Compressing objects: 100% (401/401),done.
remote: Total 1073 (delta 672),reused 1045 (delta 651)
Receiving objects: 100% (1073/1073),114.42 KiB | 128 KiB/s,done.
Resolving deltas: 100% (672/672),done.
error: unable to create file httpbin/templates/... (Is a directory)

git版本1.8.0.msysgit.0,Windows Vista SP2 x64

怎么了?

解决方法

我觉得麻烦就是这个文件在你的回购: https://github.com/kennethreitz/httpbin/blob/master/httpbin/templates/ ……

…在Windows下不是有效的文件名

为了获得repo,克隆时不检出文件(使用-n标志):

git clone -n?? git:// repo

然后你可以使用稀疏结账来获取所有文件但是…,或者你只能git你实际需要的结帐文件.

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读