Outlines
- Introduction to git
- Types of version control
- Introduction to github
- Why use github
- How to create a github account
- How to install and configure git
Introduction to git
When you are working on a simple project, such as a single page html, it is very easy to remember the last thing you changed and where the changed occurred.
Version Control Systems (VCS) help a software team manage changes to source code over time. VCS software includes tools for saving the state of a project, viewing the history of changes, and reverting changes.
Developing software without using version control is risky, similar to not having backups. VCS can also enhance and speed up development. Depending on the version control software used, many developers can work on the same code at the same time.
Types of version controls
There are two types of version control.
- Centralized version control system
- Distributed control system
Centralized VCS
All the team members or people working on the same code connect to the central server to get the latest copy of the code, and to share their changes with others. The pitfall of centralized VCS is if the server goes offline, we can’t collaborate and save snapshots of our project. So, we have to wait until the project comes back online.
Distributed Version control systems
we don’t have this problem. Every team member has a copy of the project with its history on their machine. So, we can save the snapshots of our project locally on our computer. If our server is offline, we can synchronize our work directly with others.
One of the most popular version control systems is Git, a distributed VCS.
Git has another advantage - it is distributed.
Rather than having only one single place for the full version history of a project, every developer's working copy of the code is also a repository that can contain the full history of all changes. Git was created by Linus Torvalds in 2005 for development of the Linux kernel, with other kernel developers contributing to its initial development.
Introduction to github
GitHub is the cloud-hosted Git management tool and git is Version Control System. Github helps us to share and store our code easily.
Why use github
Github helps us to share and store our code easily. With the help of github we can work on project irrespective of our location or schedule.
How to create a github account
The steps below illustrate how to create a github account;
- Load GitHub website on your browser or click GitHub
- Create a new account by clicking the sign up button and fill up necessary information such as username, email password etc.
lastly login to your github account using your registered username and password Boom you now have a github Account.
How to install and configure git
Before we can monitor or control our project, we need to have git install and configure on our local machine.
Setup and installation
You can download git from here and for installation, use these instructions provided by git (if it’s not already installed).
configuration
if it's your first time using git then you need to configure it, so that git can identify the user. follow the steps below to configure git on your local machine
Steps to configure git on your local machine(computer)
Search for command prompt on window and command Line mac
then open program to lunch the command interfaceon your command line run the command below to configure git on your machine:
git config — global user.name “Your Name”
git config — global user.email youremail@example
So far, we have been able to cover some basics of git and github, in our next article we are going to be covering How to push our project to github. Please do comment, share and like, see you in the next article.
Top comments (1)
Nice Write up, simple and well explanatory