Hi, and welcome to today's programming Tool.
Today, I'm very excited to introduce you to a new skill.
This is a must have skill for any programmer.
And this skill is.
The skill of controlling the versions of your programs, in other words.
Version control.
So version control is a practice.
That allows you to track changes in your code.
And manage those changes.
So let me explain what I'm talking about with an example.
This is the state of our code at the moment.
But let's suppose that we have an issue with the added.
Keys.
We realize that.
About five days ago, we made a change which.
Cause the issue we have now.
So what we want to do is we want to go back.
To the state of the code as it was five days ago.
You cannot do that with undue.
Because you have saved the codes already.
You have close by charm.
You have reopen it again.
So undoing the changes is not an option.
All you're left with is your memory.
You try.
You'll try to remember what you did change back then, and then try to rewrite the code as it was.
And that's not the best solution.
That's why we have version control systems.
So we have version control and version control systems.
Version control systems are software which we will install on our computer.
You will install it on your computer as well.
And that system allows you to control the versions of your programs, of your Python programs.
Practically in this case, if we had used a version control system.
With our project here, we would be able to easily go back.
And see the code as it was five days ago, and then we can reuse that version of the code.
Or just pull up certain changes from that code.
We can compare that code with our code as so we have control over the versions of our programs.
So as I mentioned, to control the version of your program, you need to use a version control system,
which is a software you install.
So now I'll mention the main version, control systems which can be used and we'll have to pick one
of them.
The first one is good.
And Git is also the most popular version control system, and that's the one we will use.
But just for knowledge, I'll also mention the other systems as well.
We have Apache Subversion Bazaar and Mercurial to mention just a few of them.
Of course, there are slight changes between those are, but the most popular one and the best one is
also get.
So we'll be using it and I will.
Take you through using it in the next day.
So tomorrow in the programming tool of tomorrow.
Today I just want to make you familiar to to make you understand what version control is.
So tomorrow we will install gates and we will connect it with our projects so that we can keep track
of our changes, so we can control the version.
But before we go to tomorrow's video, I want to show you a glimpse of a version control.
So this is one of my personal projects.
This is a.
Project, a Python based project.
Which constructs a web app, and it's based in the Django framework.
So this is the Python code base and.
If you go to this button here, of course you don't have this because you have not enabled get yet.
But I have enabled kids in this project.
So if I go to that button, I'll have access to all the changes I have made across.
Different days.
So, for example, if I want to see how my code was at this change here, when I added an exercise and
I recorded that change in here.
So I can just right click here and then I can compare that file with the local file.
So then I'll I'll see here.
The file as it was back then.
And then here on the right, I have the current view of the file, how the file is now and how the file
was back then when I made that change.
Lots of changes are highlighted, as you can see here.
And so on.
So I have recorded different changes in here.
I can click any of them and here on the right I can see the files that were changed that day.
And so on.
So that's.
How it works in a nutshell.
I'll take you through how to make these changes, how to record the changes, how to see the changes.
So don't worry about that.
This was just to show you.
Get in a nutshell.
Now this was get the software we installed to help us.
See these changes in our program.
But there's also get hope.
Maybe you have heard of it.
GitHub is a software hosting platform, so all these folders that you see here and all the files inside
them, for example, views that P inside blog.
This file is also in here in my project here.
Python home.
So that is the file.
So all these files are uploaded to GitHub.
So why would you want to upload your your program files to GitHub?
Well, that's for several reasons.
First, you can use GitHub as a backup system, so it's cloud based.
If you lose access to your files, to your hard drive.
You lose your computer, etc. Then you have the files on GitHub and I'll show you how to synchronize
your files.
So they are always up to date with the GitHub platform.
So backups is one reason.
Other reasons are you may want to share your code with other people.
So you may want to create a portfolio for potential employers to see your codes or clients.
And GetUp!
Can also be used when you want someone to collaborate with your projects.
So both you and your collaborator can make changes on your own computers and you can upload to the changes
to GitHub and.
Everything there is tracked, so everything is synchronized with the changes you have on Git.
So Git and GitHub are synchronized with each other.
Git is local and github is cloud based to back up your code and to be able to share your code with other
people.
Another rule of GitHub is that, for example, in my case.
It allows me to upload the code to the web server.
So that's the product of that code that you see here.
So this is a web app I've built in Python, and this web app has to be run in some remote servers.
So that means I have to upload all this code to that remote server and GitHub serves as an intermediary.
So I upload my code to GitHub and then I get the code from GitHub to the server.
And so that was the lecture own version, control version, control systems, Git and GitHub.
So as a summary version, control is the practice of recording the changes you do on your programs.
And the way to record your changes is to install a software which I'll cover later.
So the software itself is the version control system.
Then you have extras, which is this cloud based software hosting solution.
So such as GitHub where you can upload your code to have a backup and it also allows you to share your
code with others.
And that's about this video.
Tomorrow I'll take you through installing and using good step by step so you can use it on your computer.
So I'll see you tomorrow.
See?