Git: How to remove file from index without deleting files from any repository
- by Fletcher Moore
When you use
git rm --cached myfile
it doesn't delete from the local filesystem, which is my goal. But once you commit the changes, push them to a central repository, then pull them into another yet another repository it still deletes the file from that system.
Is there a way to just remove the file from the index without deleting it from any filesystem?