How can I commit / delete a file starting with ":"?

Someone on my team pushed a file called ": w: w" by mistake (it looks like he was trying to edit the file with VIM), but now we can't delete it.

I tried with git add \:w\:w

, but on commit, git returns an error saying the file does not match "w: w"

Is there a way to do this on the command line since we don't have permission to the repository?

+3


source to share


1 answer


You have to use double \

:

git add \\:w\\:w

      



or

git add "\:w\:w"

      

+3


source







All Articles