From the course: Software Testing Assistance with GitHub Copilot AI
Unlock the full course today
Join today to access over 24,900 courses taught by industry experts.
Use Copilot slash commands - Github Copilot Tutorial
From the course: Software Testing Assistance with GitHub Copilot AI
Use Copilot slash commands
- [Instructor] I touched on / commands earlier, but they are so powerful, they are worth revisiting here. Copilot seems to add and remove / commands with regularity. In some cases, a single word works just as well. There used to be a /doc / command, and the first one I would turn to when looking at a new code base. Instead of using doc, I'll highlight a function and just type docblock. These kind of updates are a simple way to practice Git flow on a new project, but second, the generated docs are similar to how GitHub explains code. There definitely is a /explain command. In cases where an entire function or method doesn't need to be documented, maybe a single line or a few lines, you can read through the explanation and determine what documentation or inline comments might be necessary. I haven't mentioned it before, but Copilot often suggests some follow up questions. These can lead you down a rabbit hole if you aren't careful, or they can give you just what you need. In this case…