Problem Description:
A certain day of the year, when looking at the Git library, it is extremely unreasonable to find the distribution of the file and the name of the folder, so move and rename some files.
An error occurred while deleting (git rm–rfolder) An empty file :fatal:pathspec "folder Name" did not match any files, that is, Git does not find the corresponding file. However, this folder is clearly present, just put the file inside the other folder, this folder is empty.
Problem speculation:
Someone likes to speculate that it is a bad habit, but Wood has a way. In the existing library, new folder ( empty ),git St found in my library does not need to add content, just when
I'm in an empty folder, and when Itouch new file , the library changes. The add file is only displayed when I need it. When I delete the T-ouch file git rm–f new file, the empty folder still exists, but at this point git has no hint of Add.
My analysis: git wide to my empty folder untracked, when I delete, index can not find.
Problem solving:
The clean command for git:git-clean-remove untracked files from the working tree
Git clean–fd untracked folder
Or go to the directory, delete
git rm–r folder Fatal:pathspec "" did not match any files