如何为其中包含空格的文件定义 .gitattributes 规则?

Pat*_*ter 7 git merge gitattributes

我已经阅读了.gitattributes 上的文档,并在 Stack Overflow 上搜索了这个问题的简单答案,但到目前为止还没有找到。我有一个文件,里面有空格,就像这样。

Reserved\ Slots.txt merge=mergeslots
Run Code Online (Sandbox Code Playgroud)

我还尝试使用引号而不是转义空格。

"Reserved Slots.txt" merge=mergeslots
Run Code Online (Sandbox Code Playgroud)

如何对包含空格的文件使用自定义合并驱动程序?

Wal*_*aan 6

根据.gitattributes 模式中的空白使用

[[:space:]]
# as in
has[[:space:]]spaces
Run Code Online (Sandbox Code Playgroud)