1.
Workspace agent
https://www.youtube.com/watch?v=KjyMQzoJo8Y&t=87s / Minute 7:46
https://www.youtube.com/watch?v=2nPoiUJpDaU / Minute 6:12
Copilot @workspace agent empowers our code by analyzing and understanding the entire
context of our workspace, allowing us to make recommendations that match our project’s
architecture and dependencies.
Workspace agent
2. Ask coding questions
https://www.youtube.com/watch?v=KjyMQzoJo8Y&t=87s / Minute 4:54
https://www.youtube.com/watch?v=2nPoiUJpDaU / Minute 0:49
If you are not sure or do not remember, ask Copilot about syntax or general programming
concepts without having to look through documentation or Google search. Copilot provides
answers in natural language or code snippet format. For example, let’s ask question such as
how to calculate the sum of an array?.
Also, if you want to understand the behavior of the code or how it works, you can ask for
explanations.
3. Code completions
https://www.youtube.com/watch?v=KjyMQzoJo8Y&t=87s / Minute 0:06
https://www.youtube.com/watch?v=2nPoiUJpDaU / Minute 2:05
When you start coding, Copilot analyzes the context of the file and makes suggestions from
the editor. For example, let’s start typing a method name as arraySum and Copilot will
suggest an implementation that matches our coding style:
GitHub Copilot suggestion
4. Code refactoring and improvements
https://www.youtube.com/watch?v=zYq7jMVDOIo
We can ask Copilot to refactor or improve selected code. It will analyze and suggest
refactorings or improvements using the context of our codebase.
Copilot refactoring
5. Fix it
https://www.youtube.com/watch?v=KjyMQzoJo8Y&t=87s / Minute 4:24
https://www.youtube.com/watch?v=2nPoiUJpDaU / Minute 3:20
If your code has an error or warning, Copilot can suggest possible fixes based on the error
message, code syntax, and surrounding code.
Fix suggestion
6. Generate unit test cases
https://www.youtube.com/watch?v=Psm86eIvmdc
Copilot identifies our test framework and coding style and suggests test cases to handle
errors, null values, or unexpected input data types. Let’s generate test cases for the previous
arraySum function:
Generate Tests
Generated test cases:
Generated tests
7. Generate Commit Message
https://www.youtube.com/watch?v=KjyMQzoJo8Y&t=87s / Minute 6:25
https://www.youtube.com/watch?v=2nPoiUJpDaU / Minute 5:34
If you are too lazy to write a commit message, Copilot will write for us. Let’s just click the
spark icon next to the commit message text box in VS Code.
Generate commit message
8. Language Translation
https://www.youtube.com/watch?v=pX9uMWY60sY / Minute 2:39
Now we don’t need to learn other programming languages, Copilot can translate the selected
code into other languages. Let’s translate the previous arraySum JavaScript function to
Python:
Javascript to Python
9. Rename suggestions
https://www.youtube.com/shorts/IFU1Ngqmmng
When you rename a symbol in your code, Copilot suggests a new name based on the context
of the symbol.
Let’s rename the previous arraySum function:
Rename suggestions
10. VSCode Agent
https://www.youtube.com/watch?v=KjyMQzoJo8Y&t=87s / Minute 8:09
https://www.youtube.com/watch?v=2nPoiUJpDaU / Minute 7:27
If you’re looking for a way to perform or interact with VS Code functionality, Copilot @vscode
agent can help you provide more details or clarify the functionality you’re interested in. For
example, we can describe functionality, and Copilot will help determine the corresponding
functionality in VS Code. Let’s ask add a new line to the end of the file when saving:
VSCode agent