[英]Intellij - Cannot Run Git
I have noticed that on Version Control window, in tabs Log and Local changes there is no information.我注意到在版本控制 window 中,日志和本地更改选项卡中没有任何信息。 Only following error appears:
仅出现以下错误:
Error updating changes: Cannot identify version of git executable C:\Program Files\Git\cmd\git.exe更新更改时出错:无法识别 git 可执行文件 C:\Program Files\Git\cmd\git.exe 的版本
When I have clicked Test in Settings > Version Control > Git, entered above path in Path to Git executable following window appeared: Link当我在设置 > 版本控制 > Git 中单击测试时,在出现 window 之后的 Git 可执行文件的路径中输入以上路径:链接
After typing in CMD command git --version I get output:输入 CMD 命令git --version后,我得到 output:
git version 2.17.0.windows.1
What is more after writing some code Intellij is not highlighting changes.更重要的是,在编写了一些代码之后,Intellij 并没有突出显示更改。
I don't have any idea why it is not working... Any ideas?我不知道为什么它不起作用......有什么想法吗?
I am able to resolve the issue.我能够解决这个问题。
My GIT installation directory: C:\\installations\\Git\\我的GIT安装目录:C:\\installations\\Git\\
WHAT WORKED什么有效
If I point the Git executable path to (C:\\installations\\Git\\mingw64\\bin\\git.exe) it worked.如果我将 Git 可执行文件路径指向 (C:\\installations\\Git\\mingw64\\bin\\git.exe),它就起作用了。
WHAT DIDN'T WORKED什么不起作用
For some reason, IntelliJ cannot get any output from the command line client.出于某种原因,IntelliJ 无法从命令行客户端获取任何输出。 Something similar is reported - https://youtrack.jetbrains.com/issue/IDEA-82445
有类似报道 - https://youtrack.jetbrains.com/issue/IDEA-82445
It might be caused by antivirus software or UAC.它可能是由防病毒软件或 UAC 引起的。
For me, only invalidating caches and restarting intellij worked.对我来说,只有使缓存无效并重新启动 Intellij 才有效。 :)
:)
git --exec-path
to get your git path. git --exec-path
以获取您的 git 路径。 Note: on Mac Os, use /
in finder to navigate easier.注意:在 Mac Os 上,使用
/
在 finder 中导航更容易。
i got the same problem, and the config is right,我遇到了同样的问题,而且配置是正确的,
git works just when i cut down the internet, it got from the IT part in my company. git 就在我切断互联网时起作用,它来自我公司的 IT 部门。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.