如何“在Git Bash中打开"在Github Desktop中 [英] How to "Open in Git Bash" in Github Desktop

查看:446
本文介绍了如何“在Git Bash中打开"在Github Desktop中的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

存储库的下拉菜单中,您可以看到一个名为在Git Bash中打开( Ctrl +`)的按钮,

In the dropdown menu of Repository, you can see there is a button named Open in Git Bash (Ctrl + `),

当我单击它时,我收到一条警告:

when I click it, I got a warning saying:

无法找到Git

我们无法在您的系统上找到Git.这意味着您将无法在命令提示符下执行任何Git命令.

We were unable to locate Git on your system. This means you won't be able to execute any Git commands in the command prompt.

为帮助您为操作系统安装和配置Git,我们提供了一些外部资源.

To help you get Git installed and configured for your operating system, we have some external resources available.

问题是我已经从 git-scm.com 下载了最新的Git.

The problem is that I have already downloaded the latest Git from git-scm.com.

最后,我应该如何配置我的Github Desktop或Git Bash(MingW)以使此按钮(在Git Bash中打开)起作用?

推荐答案

要使Github Desktop成功定位Git,必须在环境变量%PATH%中给出Git的URI.

To make Github Desktop locate Git successfully, the URI of Git must be given in environment variable %PATH%.

我建议分配Git的URI的%GitPath%值,例如C:\Program Files\Git\bin;然后将%GitPath%附加到%PATH%的末尾,不要忘记路径分隔符(;).

I suggest to assign %GitPath% value of URI of Git, say C:\Program Files\Git\bin; then append %GitPath% to the end of %PATH%, and don't forget about path seperator (;).

最后,如果环境变量仍在运行,请在分配环境变量后重新启动Github Desktop.

At last, restart Github Desktop after assigning the environment variables, if it is still running.

参考:

这篇关于如何“在Git Bash中打开"在Github Desktop中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆