win10 右键菜单添加Git Hash Here

1、通过在“运行”中输入‘regedit’,打开注册表。

2、找到[HKEY_CLASSES_ROOT\Directory\Background]。

3、在[Background]下如果没有[shell],则右键-新建项[shell]。

4、在[shell]下右键-新建项[open in git],其值为“Git Bash Here",此为右键菜单显示名称。(可以直接新建项Git Bash Here)

5、在[shell]下右键-新建-字符串值[Icon],双击编辑,其值为“D:\Tools\VersonCtrs\Git\Git\mingw64\share\git\git-for-windows.ico”。此为菜单加图标。

6、在[open in git]下右键-新建-项[command],其值为"D:\Tools\VersonCtrs\Git\Git\bin\bash.exe" --login -i。

7、reg文件导出,包括删除和添加。

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\Directory\Background\shell\Git Hash Here]
"Icon"="C:\\Program Files\\Git\\mingw64\\share\\git\\git-for-windows.ico"
@="Git Hash Here"

[HKEY_CLASSES_ROOT\Directory\Background\shell\Git Hash Here\command]
@="\"C:\\Program Files\\Git\\bin\\bash.exe\" --login -i"

删除

Windows Registry Editor Version 5.00

[-HKEY_CLASSES_ROOT\Directory\Background\shell\Git Hash Here]

 

 

参考:

https://www.zhihu.com/question/48091139/answer/109144599

http://www.bubuko.com/infodetail-1263581.html

http://www.cnblogs.com/JoshuaDreaming/archive/2011/12/01/2270254.html

转载于:https://www.cnblogs.com/kissfu/p/6252518.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值