Git源代码管理提供者热键

编程入门 行业动态 更新时间:2024-10-26 09:19:07
本文介绍了Git源代码管理提供者热键的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我为Visual Studio 2010使用了 Git Source Control Provider 扩展,我想为Commit提供一个热键,但我无法使其工作。我想通过右击解决方案中的任意位置来定义键盘快捷方式,通过右键单击解决方案中的任意位置,选择Git-> Commit(带牛图标的那个,而不是TortoiseGit提供的那个)。

我为GitPlugin.Connect.GitExtensionsCommit设置了一个热键( Ctrl + G , Ctrl 全球使用(是的,我不得不禁用一些其他使用Ctrl + G的热键设置),但是每当我使用它时,我都会收到一条错误消息,指出该命令当前不是

如何为Git Source Control Provider设置热键?

解决方案

我将Ctrl + \,Ctrl + K配置为快捷键(但您可以只要没有冲突就设置你自己。)

之后,如果选择任何项目/文件节点并点击快捷方式,它将触发提交。

catch 这里是你必须在中选择项目或文件 c $ c>解决方案资源管理器这是有道理的,因为否则,提供者不知道要提交什么。

I'm using the Git Source Control Provider extension for Visual Studio 2010, and I'd like to set a hotkey for Commit, but I can't make it work. I'd like to define a keyboard shortcut for whatever command is run by right-clicking anywhere in my solution, selecting "Git->Commit" (the one with the cow icon, not the one provided by TortoiseGit).

I've set a hotkey for GitPlugin.Connect.GitExtensionsCommit (Ctrl+G, Ctrl+C), to be used globally (yes, I had to disable some other hotkey settings that used Ctrl+G), but whenever I use it I get an error message saying that the command is not currently available.

How do I set hotkeys for the Git Source Control Provider?

解决方案

After playing around with this, I was able to get it working.

I configured Ctrl+\, Ctrl+K to be the shortcut (but you can set your own as long as there are no conflicts).

After that, if you select any project/file node and hit the shortcut, it'll trigger the commit.

The catch here is that you have to select a project or file in solution explorer which makes sense because otherwise, the provider doesn't know what to commit.

更多推荐

Git源代码管理提供者热键

本文发布于:2023-05-31 22:06:57,感谢您对本站的认可!
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:热键   提供者   源代码   Git

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!