2026-04-07
Git is an open-source version control system which tracks changes to local files. It was originally developed by Linus Torvalds, the creator of the Linux operating system kernel.
Image: Torvalds’ initial commit.
The username and email
You can check your configuration settings with:
Learn more: Setting your commit email address
A hidden folder called .git is created in the directory which stores the history of the repository
Learn more: Cloning a repository
List which files are staged, unstaged, and untracked.
Add file(s) to staging area
Take a snapshot of the state of the repo
Image: Allison Horst.
A .gitignore is a text file that lists all of the files and folders that you don’t want tracked by Git. For example, this list could include datasets that contain sensitive data.
GitHub hosts Git repositories online.
Learn more: Creating a new repository.
Make the GitHub repository a remote for the local repository
Verify remote
Learn more: Adding locally hosted code to GitHub.
A README provides information about the purpose and contents of a GitHub repo. Each README file is written using Markdown, a simple formatting syntax for plain text documents that can be easily converted into HTML.
Learn more: Basic writing and formatting syntax.
If you are collaborating with others it is generally a good idea to create what’s called a branch. This is essentially a sandbox for testing out code. The working code is on the main branch but the experimental code is held on a separate, isolated branch.
These are the steps that you might follow:
git branch devgit checkout devgit push -u origin devLearn more: Git Branch.