1. When creating a new code file, do not pay attention to the file name should be a small write wrong
2. The file has been push to the remote.
3. Change the name of the file to full lowercase under windows
After you've changed it, nothing happens in git, and when you use git status, git case is not sensitive, as follows:
123456 |
[Rock@Rock-PC]$ /d/wampserver/www/ Hexu. org/code (dev) $ git status on branch master Your Branch is up – to –date with ' Origin/master '. Nothing -to-commit, working directory Clean |
How do you solve the problem of git size insensitivity?
1. Scenario one is to set git case sensitivity:
1 |
$ git config core. ignorecase false |
2. Option two is to delete the file before adding it:
1 |
$ git rm ; git add ; git commit -m "rename file" |
Since I am a warehouse shared with everyone, I used the solution 2.
12345678910111213141516 |
$ git rm code/Library/buildtag*. php; git status on branch Dev changes to be committed: (use "git reset HEAD ..." to unstage) deleted: code/Library/BUILDTAGAFC. php deleted: code/Library/buildtagafs. php rock@rock-pc /d /wampserver/www< Span class= "Crayon-o" >/hexu.org/code (dev /span> $ git add code/Library/buildtag*. php; git status on branch Dev changes to be committed: (use "git reset HEAD ..." to unstage) renamed: code /library/ Buildtagafc.php - > code/library/buildtagafc.php renamed: code/Library/buildtagafs. php -> ; Code/Library/buildtagafs. php |
Http://blog.hexu.org/archives/1909.shtml
How do I configure GIT to support case sensitivity and to modify uppercase and lowercase letters in filenames? Go