当某些文件名包含星号时,无法在Windows上克隆git repo [英] Can't clone git repo on windows when some file names contain asterisk

查看:259
本文介绍了当某些文件名包含星号时,无法在Windows上克隆git repo的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的存储库中具有以下名称的文件:

I have files with the following name in my repository:

*.example.com.crt

问题是我无法在Windows上克隆存储库.

The thing is that I can't clone the repository on windows.

error: unable to create file *.example.com.crt (Invalid argument) Checking out files: 100% (6122/6122), done. fatal: unable to checkout working tree warning: Clone succeeded, but checkout failed.

error: unable to create file *.example.com.crt (Invalid argument) Checking out files: 100% (6122/6122), done. fatal: unable to checkout working tree warning: Clone succeeded, but checkout failed.

您知道任何解决方法吗?

Do you know any workaround for that?

推荐答案

不幸的是,没有. Windows 禁止文件名中的某些字符,而Git将支持几乎所有内容,因此,由您来管理它.我认为您最好的解决方案是简单地重命名文件.

Unfortunately, no. Windows disallows certain characters in the filename, and Git will support just about anything, so it's up to you to manage it. I think your best solution is to simply rename the file.

就个人而言,无论如何我都避免在文件名中使用*,因为它是glob字符.

Personally, I'd avoid using * in a filename anyways, since it's a glob character.

这篇关于当某些文件名包含星号时,无法在Windows上克隆git repo的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆