HomeVideos

GitHub Copilot app for beginners: using the diff, terminal, and browser

Now Playing

GitHub Copilot app for beginners: using the diff, terminal, and browser

Transcript

86 segments

0:00

When an agent makes a change,

0:01

you’ll want to review it, run it, and see it.

0:04

The good news is that you can do all three

0:06

without leaving the app.

0:07

Normally, those three jobs would mean

0:09

bouncing between your editor,

0:10

a terminal window, and a web browser.

0:12

Here, they live side by side as built-in panels,

0:15

so checking an agent’s work is quick

0:17

instead of a chore.

0:18

Let’s tour them one at a time.

0:25

A diff shows exactly what changed,

0:26

with additions in green and deletions in red,

0:29

so nothing is a mystery.

0:30

If you’re new to the word,

0:31

a diff is simply a before and after comparison,

0:34

the lines that were added, removed, or changed,

0:36

usually colored so that they jump out.

0:38

And you’re not just a passive reader.

0:40

You can accept changes, leave comments,

0:42

or ask Copilot to adjust.

0:44

This is where you stay the decision maker,

0:46

and nothing is final until you say so.

0:48

Now, reading code is good, but running it is better.

0:52

The terminal panel lets you

0:53

run commands right inside the session.

0:55

If a terminal looks intimidating, relax.

0:58

Here, you’re mostly just running

0:59

the project’s own commands

1:00

and reading the results.

1:01

For Tailspin Toys, I’ll start the app.

1:04

We can do it here by hand,

1:06

or we can configure it as a script,

1:08

and then always have it available

1:10

with the ‘Run’ button.

1:11

So here, I’ve added the ‘Dev server’ script

1:14

that opens the client folder

1:15

and then runs ‘npm run dev’.

1:17

If we click ‘Run’,

1:19

this will start the server for the website.

1:21

So the ‘Run’ action opened a new terminal window,

1:24

but we still have our existing terminal window

1:26

as another tab.

1:27

So we can jump back if we want to,

1:29

to continue running commands.

1:31

For anything with a user interface,

1:33

the browser panel closes the loop.

1:35

Tailspin Toys is a website, so I can open it,

1:37

and actually use the new feature

1:39

the same way a real user would.

1:41

Here, if I wanted to keep iterating,

1:43

I can use the ‘Pick & Polish’ tool

1:45

to select this element

1:47

and then continue to work with the agent

1:49

because I’ve added it as context.

1:51

So now we can run our dev server again,

1:53

after I’ve made any changes,

1:55

and then we’d be able to see the fix.

1:56

So we were able to review the diff,

1:59

run it in the terminal, and see it in the browser,

2:02

and immediately iterate over it

2:03

to get a working sort feature.

2:05

There’s no tab hopping, no switching apps,

2:07

no losing your place.

2:09

That’s the tight loop and the whole point.

2:11

The faster you can go from change to confidence,

2:13

the more comfortable you’ll be letting agents help.

2:16

Once we’re happy,

2:17

we can accept the change right here

2:18

and create a PR, and move on.

2:20

Having review, run, and preview side by side

2:23

is exactly what makes agent-made changes

2:25

feel safe instead of scary,

2:27

because you’ve seen the proof

2:28

with your own eyes.

2:29

Together, these built-in panels

2:31

answer the three questions

2:32

you should always ask about an agent’s work:

2:35

What changed?

2:35

Does it run?

2:36

And does it actually work?

2:38

Make this your habit.

2:39

Next time an agent edits your code,

2:41

open the diff, run the tests, and preview it live,

2:44

before you accept.

2:45

Give it a try with GitHub Copilot app at gh.io/app.

Interactive Summary

The video demonstrates how the GitHub Copilot app streamlines the process of reviewing and verifying code changes made by AI agents. By integrating diff views, a terminal, and a browser preview into a single interface, the app eliminates the need to switch between different tools, allowing users to efficiently review changes, execute commands, and verify features in a closed loop.

Suggested questions

3 ready-made prompts