Python for Entrepreneurs Transcripts
Chapter: Source Control and Git
Lecture: Introducing GitHub

Login or purchase this course to watch this video and the rest of the course contents.
0:01 We are taking a look at the source control concept and the implementation
0:04 known as Git so far in this video course.
0:06 And now we are going to talk about GitHub.
0:08 GitHub is a cloud service that allows us to store and manage our Git repositories;
0:14 GitHub is certainly not required for using git but it's often conflated with git
0:19 by new developers, because they are used hand in hand in many different projects.
0:24 Let's get some clarity on the difference
0:26 between Git, the source control system and GitHub, the cloud service.
0:30 Git is an implementation of the source control concept,
0:34 so it is a specific tool that we use from the command line.
0:38 And it simply allows us to store and manage our code in repositories.
0:43 GitHub on the other hand is a company that provides a web application
0:46 for managing Git repositories, it makes it much easier to use git
0:51 because now we have a user interface
0:53 with which you create and manage Git repositories if we choose;
0:57 it hosts the remote repositories, so the great part about this is
1:00 it's providing a back up service,
1:03 if our laptop that we're developing our business on suddenly crashes,
1:06 we know we have an exact copy up on GitHub
1:09 and we can always just sync our new laptop and grab all the files that we were working on.
1:13 GitHub also makes it easier to work with other people, so for example,
1:17 later in this course we'll talk about contractors and if you hire contractors
1:21 it's often easier just to give them access to your code through GitHub
1:24 rather than them having to sync their repositories with your repositories
1:28 and just use laptops, you can use GitHub as a central location for your source code.
1:33 GitHub is also going to assist us with our deployments later,
1:36 so as we go on to build our application, and we're ready to deploy it to a cloud server,
1:41 we are going to use GitHub as a bridge between the code that we have in our Git repository
1:45 and the location that we're going to deploy it to.
1:49 And here is how Git works.
1:51 Let's say all of my code and everything that I've been working on
1:54 are in a Git repository on my local laptop.
1:57 Then, I create a repository on GitHub, I'll push all my code up there,
2:01 I'll use the "git push" command, so that I have a remote repository to push code to.
2:05 So I'll say something like "git push origin master",
2:09 we'll take a look at these exact commands
2:10 once we get into the Git specifics in the next section.
2:13 But for right now, this is just an overview of what we're doing.
2:16 We can also pull the code down, so for example if I'm working with someone else
2:20 and they've pushed their code up to GitHub,
2:22 I can then pull it down with the "git pull" command,
2:24 it makes it really easy to have a central location for all of the code
2:28 that way if I'm working on it on my own,
2:30 I can simply be assured that I have a place that it's all backed up,
2:33 or if I'm working with other people, it's not only backed up
2:36 but we know that we have the source of truth for our code.
2:39 An important concept with GitHub is that there are both public and private repositories,
2:44 when you sign up for GitHub, which we'll do in the next video,
2:47 you'll get unlimited public repositories,
2:50 now the one thing you need to really be careful of,
2:52 is that your code is visible to the entire internet, anyone can see a public repository,
2:57 it's an all or nothing deal, either it's public and everyone can see it
3:00 or it's private and only you can see it
3:03 along with the people that you've manually added to that project.
3:07 Now personal accounts are $7 a month for the private repositories
3:11 they are also free for students, if you are a student,
3:13 you should be able to get access to as many private repositories as you want just for free;
3:17 while I know $7 a month can be cost prohibitive in some cases,
3:20 I highly recommend that you get a personal account for the $7 a month
3:24 when you start building your business, that way you can keep your code private.
3:28 While you are working through these videos, you can just simply use a free GitHub account,
3:31 and upgrade it when you're ready to start your business.