git Staging Deleted files

Use git rm foo to stage the file for deletion. (This will also delete the file from the file system, if it hadn't been previously deleted. It can, of course, be restored from git, since it was previously checked it.)

To stage the file for deletion without deleting it from the file system, use git rm --cached foo

from: http://stackoverflow.com/questions/12373733/staging-deleted-files

原文地址:https://www.cnblogs.com/pinganzi/p/5310197.html