【发布时间】:2021-01-27 10:33:28
【问题描述】:
我在 .gitignore 中添加了这样的内容:
Pods/
MyStarhub.xcworkspace/
*/xcuserdata/
DerivedData/*
Podfile.lock
*.DS_Store
*.icloud
但 git 出于某种原因一直在跟踪 .Ds_Store Podfile.lock。
【问题讨论】:
我在 .gitignore 中添加了这样的内容:
Pods/
MyStarhub.xcworkspace/
*/xcuserdata/
DerivedData/*
Podfile.lock
*.DS_Store
*.icloud
但 git 出于某种原因一直在跟踪 .Ds_Store Podfile.lock。
【问题讨论】:
可能是因为 git 仍在跟踪您之前推送的文件。试试:
git rm --cached .DS_Store
git rm --cached Podfile.lock
或者干脆删除文件,提交并推送
【讨论】: