本文介绍了如何在这里添加“打开git-bash ...”上下文菜单到Windows资源管理器?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何在windows资源管理器中添加一个上下文(aka右键单击)菜单,点击后在当前资源管理器文件夹中打开git-bash控制台?

解决方案

我有类似的问题,并且我做到了这一点。

第1步:输入regedit开始菜单

第2步:运行注册表编辑器



步骤3:导航到 HKEY_CURRENT_USER \SOFTWARE \Classes\Directory\Background\shell



右键单击shell并选择New> Key。命名键Bash







第6步:在Bash下创建一个新密钥并将其命名为command。将此键的值设置为您的git-bash.exe路径。









关闭注册表编辑器。



您现在应该能够在资源管理器中的右键菜单中看到该选项。 b

PS 默认情况下,Git Bash会接收当前目录。 em> :如果您想要一键式方法,请查看Ozesh的


How to add a context (aka right click) menu to the windows explorer that, when clicked, opens the git-bash console in the current explorer folder?

解决方案

I had a similar issue and I did this.

Step 1 : Type "regedit" in start menu

Step 2 : Run the registry editor

Step 3 : Navigate to HKEY_CURRENT_USER\SOFTWARE\Classes\Directory\Background\shell

Step 4 : Right-click on "shell" and choose New > Key. name the Key "Bash"

Step 5 : Modify the value and set it to "open in Bash" This is the text that appears in the right click.

Step 6 : Create a new key under Bash and name it "command". Set the value of this key to your git-bash.exe path.

Close the registry editor.

You should now be able to see the option in right click menu in explorer

PS Git Bash by default picks up the current directory.

EDIT : If you want a one click approach, check Ozesh's solution below

这篇关于如何在这里添加“打开git-bash ...”上下文菜单到Windows资源管理器?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

10-30 01:56