.DS_Store still appears in git status despite being in .gitignore

后端 未结 2 829
暖寄归人
暖寄归人 2020-12-16 01:21
$ cat .gitignore 

# OSX
*/.DS_Store
.DS_Store
.DS_Store?
._*
.Spotlight-V100
.Trashes
Icon?
ehthumbs.db
Thumbs.db

$ git status
On branch develop
Changes not staged         


        
2条回答
  •  醉话见心
    2020-12-16 01:55

    Make sure .DS_Store isn't in the cache:

    git rm --cached -- Assets/Sprites/.DS_Store
    

提交回复
热议问题