-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
29 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
## 远程-本地文件名大小写冲突 | ||
|
||
例如远程 `src/views/abutmentWay.vue`, 本地 `src/views/AbutmentWay.vue` | ||
|
||
## 解决方法: | ||
|
||
1. 删除远程文件: | ||
|
||
```zsh | ||
git rm --cached src/views/abutmentWay.vue | ||
git commit -m "chore: Remove file with incorrect case" | ||
git push | ||
``` | ||
|
||
2. 然后添加并推送正确的文件: | ||
|
||
```zsh | ||
git add src/views/AbutmentWay.vue | ||
git commit -m "fix: Add file with correct case" | ||
git push | ||
``` | ||
|
||
## 设置项目Git要区分大小写 | ||
|
||
```zsh | ||
git config core.ignorecase false | ||
# 或者设置全局 | ||
git config --global core.ignorecase false | ||
``` |