Is it possible to ignore deleted files in git? git update-index --assume-unchanged allows me to ignore modifications, but it still tracks deletions.
(This is similar, but I couldn't find where "John Doe" restated his question: Ignore modified (but not committed) files in git?)
Rather than trying to ignore the "delete" status, I would:
Note: that may not be compatible with a Git repo currently synchronized with a SVN one.
The following stops will surely solve your problem:
Ensure that all deleted files are not staged to commit.
If they are staged, to unstage them you can simply do git reset
After this step, run the following command
git ls-files --deleted -z | git update-index --assume-unchanged -z --stdin
Note: The first command. git ls-files --deleted -z
, lists all the deleted files as a string. Then it takes that as the input to the second command.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With