- [Instructor] All the files for this course
are freely available as GitHub repo at this URL.
I assume that you have a Git client already installed
on your machine and have some basic knowledge
about what Git and GitHub are and how they work.
If you're completely new to Git,
I recommend you to take the course
"Learning Git and GitHub" by Ray Villalobos.
As Git and GitHub are so commonly used, I promise you
that this is a good investment into your career.
The repository is built in a way so
that there are branches for each of the videos
in this course where code was changed.
You can use the branch pop-up right here
on the left to switch between branches.
If you see a B at the end of the branch name,
this means this is how the code looked
at the beginning of the video.
And if you see an E, this means
that this is how the code looked at the end of the video.
The main branch that I have opened now
contains the initial state, so this is your starting point.
This is how the code looks at the beginning of this course.
I also created a separate branch, "final,"
and this final branch contains the state
of the code at the very end of this course.
To download all the files to get started,
you have to clone this Git repository and I will show
you now how you can fetch all those branches.
If you want to make changes and commit them back to GitHub,
you may also fork this repository and clone it from there.
So this "Fork" button is on the top, right here.
I will now clone this repository.
For that, I click on this green button labeled
with "Code," and there, I first copy this https URL.
Next, I open the terminal window.
I'm on a Mac, but on Windows you have something similar.
And there, I now change to my desktop folder.
You can use any folder you want.
Just test to make sense for you.
And in this folder, I will now create a new folder
for this course material, so I do it,
"mkdir node-databases," and then
I change into this directory.
Now we will do the actual cloning of this GitHub repository
and to pull down all branches is way more complicated
than one might think, so just follow along with me.
So I'm in my "node-databases" directory,
and now I run "git clone," and then "--bare,"
and then I paste in the repository URL
that we just copied for, and in the very end,
and this is important, I add ".git."
Now I hit return.
So this looks good so far, but we're not done yet.
Next I will now run "git config --bool core.bare"
and this is followed by "false."
Now let's hit return again.
And this command does not return anything.
And now I do a "git reset --hard."
Now at the very end, I run "git branch."
And we see now the list of all branches, so now you have
all branches pulled down to your local machine.
So let's open Visual Studio Code now real quick.
And then open the directory that we just created,
So the select, open, and then my desktop
and "note databases" and then I select open again.
And now you see that we have this "note-databases"
directory open and down there, you also see
that we are on the main branch,
so we are now at the initial state of this application.
When you click on this main branch,
you also see all these other branches.
So now you can really switch freely
through all these branches, so if you want
to get the final state of this course,
you simply select "final," and there you are.
But I recommend to you is now to create a dedicated branch
for your work directly from main.
So I click on "main," and there,
I select "create new branch," and I call it "development."
Don't get distracted if, during this course,
my screen sometimes shows another branch.
You can just stay on development.
With that, all done, we will have a closer look
at our demo applications in the next video.