'git add -u' 暂存所有 repo 文件

问题描述

出于团队流程的目的,我在 Linux(centOS 7.5.1804,git 版本 1.8.3.1)上有一个本地 GIT 存储库。在我这边,我从 Windows、Sublime Merge 或直接从 gitbash(windows 10,git 版本 2.31.1.windows.1)管理它。 我在 Sublime Merge 上直接打开 linux Repo(通过 Windows 上的网络地图),或者转到 gitbash 上的 linux 目录。 如果我修改了几个文件(例如 3 个),当我在 Sublime Merge 上使用“Stage All”或在 gitbash 上使用“git add -u”时,我会暂存我的所有 repo 文件(在我的情况下为 300)。 Sublime Merge 为每个文件显示附加警告。 .gitattributes 示例:

警告:LF 将被 .gitattributes 中的 CRLF 替换。 该文件将在您的工作目录中以原始行结尾

我已验证文件,所有文件(已修改或未修改)或 Linux 行尾 (LR):已在 Windows 上使用 VSCode、sublime text 和 notepad++ 进行检查。

在 gitbash 上,“git status”将我所有的 300 个 repo 文件列为已修改且未暂存。 我在同一个 Repo 上的 linux 术语没有问题。

我的 git 在 windows 上有什么问题,以及如何能够在我的 linux Repo 上使用 windows 现代 GIT GUI 软件?

谢谢。

信息: Windows 上的“git config --list --show-origin --show-scope”

system  file:C:/Program Files/Git/etc/gitconfig http.sslcainfo=C:/Program Files/Git/mingw64/ssl/certs/ca-bundle.crt
system  file:C:/Program Files/Git/etc/gitconfig http.sslbackend=openssl
system  file:C:/Program Files/Git/etc/gitconfig diff.astextplain.textconv=astextplain
system  file:C:/Program Files/Git/etc/gitconfig credential.helper=manager-core
system  file:C:/Program Files/Git/etc/gitconfig core.fscache=true
system  file:C:/Program Files/Git/etc/gitconfig core.symlinks=false
system  file:C:/Program Files/Git/etc/gitconfig pull.rebase=false
system  file:C:/Program Files/Git/etc/gitconfig credential.https://dev.azure.com.usehttppath=true
system  file:C:/Program Files/Git/etc/gitconfig init.defaultbranch=master
global  file:C:/Users/john/.gitconfig           user.email=john.doe@discret.com
global  file:C:/Users/john/.gitconfig           user.name=john
global  file:C:/Users/john/.gitconfig           diff.tool=p4merge
global  file:C:/Users/john/.gitconfig           difftool.p4merge.path=C:\Users\john\Perforce\p4merge.exe
global  file:C:/Users/john/.gitconfig           merge.tool=p4merge
global  file:C:/Users/john/.gitconfig           mergetool.p4merge.path=C:\Users\john\Perforce\p4merge.exe
global  file:C:/Users/john/.gitconfig           mergetool.keepbackup=false
global  file:C:/Users/john/.gitconfig           core.autocrlf=false
local   file:.git/config                        core.repositoryformatversion=0
local   file:.git/config                        core.filemode=true
local   file:.git/config                        core.bare=false
local   file:.git/config                        core.logallrefupdates=true
local   file:.git/config                        core.autocrlf=false
local   file:.git/config                        remote.origin.url=https://server.com/git/project.git
local   file:.git/config                        remote.origin.fetch=+refs/heads/*:refs/remotes/origin/*
local   file:.git/config                        branch.john_branch.remote=origin
local   file:.git/config                        branch.john_branch.merge=refs/heads/john_branch

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)

相关问答

Selenium Web驱动程序和Java。元素在(x,y)点处不可单击。其...
Python-如何使用点“。” 访问字典成员?
Java 字符串是不可变的。到底是什么意思?
Java中的“ final”关键字如何工作?(我仍然可以修改对象。...
“loop:”在Java代码中。这是什么,为什么要编译?
java.lang.ClassNotFoundException:sun.jdbc.odbc.JdbcOdbc...