【发布时间】:2017-03-06 12:34:21
【问题描述】:
我的 git 存储库中有 ~$itial Problem Description.docx 文件。
我猜它是 Microsoft word 的恢复类型文件。
我把它添加到了repo中,不小心推送了。
当我尝试做 git rm --cached ~$itial Problem Description.docx
它说 - '~ Problem Description.docx' 没有匹配任何文件
我如何git rm --cached 这个?我应该在我的.gitignore 中输入什么来忽略它?
【问题讨论】:
-
你试过 git -rm --cached '~$itia Problem Description.docx' 吗?
-
添加 *~ 到你的 .gitignore
-
添加 ~* 到你的 .gitignore
标签: git version-control gitlab