What are Git and GitHub
Draft: this lesson is an outline and will be expanded.
When you work with an AI helper, it changes your files quickly, and sometimes it changes them in a way you do not want. You need a way to try a change safely and go back if it goes wrong. Git is a program that remembers the history of a folder of files, so you can return to an earlier state. GitHub is a website that stores a copy of that history online, so you can share it, work with other people and keep a backup. In this lesson you will learn these ideas and create your GitHub account.
What you will do
- Learn the main words:
- A repository is a project folder together with its history.
- A commit is a saved checkpoint in that history, like a save point in a game.
- A branch is a separate line of work, where you can try something without touching the main version.
- A pull request is a request to bring the work from one branch into another, with a chance for people to review it first.
- Ask your AI helper: “Explain Git and GitHub with a game save-point example, in four sentences.” Compare its answer with the words above.
- Create a free GitHub account on the GitHub website. Choose a username you would be happy to show to an employer, because it becomes part of your public address.
- Turn on the extra sign-in protection that GitHub offers for your account, and keep your recovery codes in a safe place.
- Look around your profile page and find where repositories are listed. It will be empty for now.
Safety note: a repository can be public, which means anyone can read it, or private. Never put passwords, keys or personal documents in a public repository.
Check yourself
- You can explain the difference between Git and GitHub in one sentence each.
- You have a GitHub account with extra sign-in protection turned on.
- You can say what a commit, a branch and a pull request are.