.DS_Store 檔案已被忽略超過 3 年
.DS_Store 檔案已開始在修改后的“git status”中列出。
~/.gitignore_global 有條目 .DS_Store
.gitconfig 有清單 core.excludesfile=/Users//.gitignore_global
git check-ignore -v -n .DS_Store 輸出 > :: .DS_Store
釀造升級混帳
macOS 11.7 git 2.38.1
git 用戶 8 年以上
uj5u.com熱心網友回復:
git config您的or沒有任何問題gitignore。
Git 的gitignore規則只影響索引中尚不存在的檔案。因此,.DS_Store必須出現在您的檔案中,git status因為有人添加并提交了它,并且您現在已檢出該提交(或后代提交)。
所以要讓 Git 停止顯示它的狀態,您需要將它從索引中洗掉。你可以這樣做git rm --cached ...
轉載請註明出處,本文鏈接:https://www.uj5u.com/houduan/536310.html
