Git ignore deleted files

后端 未结 4 1662
灰色年华
灰色年华 2020-12-28 07:57

I have a website project that has more than 50,000 unimportant files (to development) in some directories.

/website.com/files/1.txt
/website.com/files/2.txt
         


        
4条回答
  •  太阳男子
    2020-12-28 08:56

    Ignoring a whole directory didn't work. I had to do this:

    for i in `git status | grep deleted | awk '{print $3}'`; do git update-index --assume-unchanged $i; done
    

提交回复
热议问题