GitHub Copilot is a coding assistant powered by Artificial Intelligence (AI), which can run in various environments and help you be more efficient in your daily coding tasks. In this new series of content, we will show you how GitHub Copilot works in Visual Studio specifically and how it helps you being more productive.
In this installment, we will demonstrate the usage of Slash Commands. Like my colleague Bruno Capuano calls them in the new short video we just published, Slash Commands are like "little magic spells"; in other words, by typing a slash (/) in a GitHub Copilot prompt, you open a choice where you can choose some commands which will have a predefined action.
In order to open the Slash Commands menu, you can click on the Slash button inside the GitHub Copilot Chat window.
Another option is to simply type a slash character into the message box directly. Either action will open the menu which looks like this:
Let's review the commands together.
We will get more in details about each of these commands in future posts.
In the short video, Bruno is showing how the /fix command works. There are a few typos and other issues in the selected code, and GitHub Copilot proposes a solution. As Bruno shows, the Slash Commands also work in the inline chat dialog which can be opened within any code file by typing Alt-Slash (Alt-/) or by right clicking and selecting "Ask Copilot" from the context menu.
As always, you can find more information, in our collection with resources here. Also, you can see the full-length video here.
Stay tuned to this blog for more content posted regularly. And of course, you can also subscribe to our YouTube channel to get more video content!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.