Tuesday, May 11, 2021

Add Git Commands to the Visual Studio Toolbar

 I wanted to be able to quickly access the Git "Manage Branches" from the toolbar.


Here is how to do it:

  1. Go to View >> Toolbars >> Customize
  2. Switch to the "Commands" tab
  3. Then radio check the "Toolbar" option and in the drop down select "Standard" (in my case, I wanted to add it to the standard toolbar. You can add it to a new toolbar or a different toolbar).
  4. Click on the "Add Command" button
  5. Select "View" under categories
  6. Select "GitRepositoryWindow" and also optionally the "GitWindow"


  7. You now have easy access to the commands:



2 comments:

  1. That's fine because those two toolbar options were available. I want to add commonly used Git commands to a toolbar. Things like Pull, Push, Commit, ... How do I do that?

    ReplyDelete
  2. This works because those two commands happen to be available. I want a toolbar with the Git commands I use frequently. Like Pull, Push, Commit, ... How do I get those?

    ReplyDelete

Remember, if you want me to respond to your comment, then you need to use a Google/OpenID account to leave the comment.