clock  Mon - Sun 8.00 AM - 8.00 PM
play store

What is git and github

writter  Hariom Prajapati
Date  18 Jun 2022
Language  Blog
What is git and github

What is git and github

In this article we will talk about git and github, if you do coding then this is a very important topic for you. Both git and github are different tools, their work is totally different from each other. 


What is GIT?

Git is a version control system. Which keeps information of any change in our files. Which we can easily revert or undo.


For example- if you have a project in which you change any code and because of that any problem or bug is created and if you need old file, so you can do it easily with the help of Git command . with the help of git many coders can code simultaneously on a given project from anywhere.


let's know how to install git in your PC.


How to install GIT in your PC?

Step 1 - Open in your browser and Click on downloads.

How to install GIT


Step 2 - choose your operating system And download the file.

How to install git 2


Step 3 - Install the downloaded file.


Step 4 - Open the terminal or command to check whether the installation process is completed correctly or not.


For check open terminal or command prompt and then type version of git on it.


If your window is opening, then you have installed the Git correctly , otherwise you can google it for take its solution and install it again.


How to use GIT?

To use Git you will need a terminal and a command prompt from which you can run the Git command. take the location of the folder on which you want to use Git and type.

$ cd folder location

in the terminal, by doing this, you create directory of that folder and then any command you run in the terminal will be valid for that folder only.


Basic commands for Git

→  Git init

$ git init

Using Git init we create an empty Git repository. Before using any git command, we need to initialize the git of that repository.


→  Git add

$ git add .

For all files that you use in the project, we need to move it to the staging area, for that we use the git add command.


→  Git commit

$ git commit -m "commit massage in quote"

After moving the files to the staging area, we use the Git commit command to create a checkpoint and along with it give a committed massage so that we know what we have changed or added on this commit. Every checkpoint has a unique code, with the help of that we can come to that checkpoint at any time.


→  Git status

$ git status

With the git status command, we know about all the changes that have been made so far.


→  Git branch

$ git banch branch_name;

With the help of git branch command we can create a new branch.

For example- if we want to create a branch named abc then we will type - git branch <abc> and then branch will be created.


→  Git checkout

$ git checkout branch_name;

By using git checkout command, we can move from one branch to another ,if we had created a branch named abc earlier but now we were only in the master branch, we need to run git checkout <abc> command to go to abc branch . Which will bring us to the abc branch.


→  Git merge

$ git merge branch_name;

By help of Git merge command, we can merge any branch which present in your Git.

For example- If you are currently in master branch and we have to merge abc branch in master branch then we will run git merge <abc> command.

Note : there are many Git command which we discuss in another article or you can google it.


What is Github?

Github is an online platform where we can save our created project online. With the help of which we can access our project from anywhere at any time. Github also called as a social media platform of coders where many coders can work together on team work. More than fifty million coders will be work on Github. By using Github we can easily connect and work with them. We can connect Github to our computer with the help of git command.

Comments 0

Leave a comment

Coursera, Codeacademy, Udacity, W3Schools, Udemy, Alison, TheNewBoston, edX, P.S.Codewars,Freecodecamp, Managing technical debt blog, Scrimba, Codepen, Codepen/challenges, The Odin Project, htmlreference.​io, cssreference.​io, Frontend Mentor, Dev Challenges, MDN, Code Mentor, Coding Dojo, CSS Battle, Codier, Ace Frontend, Can I Use, CSS Tricks, 30 Seconds of Code,tutorialspoint, Neumorphism, Shaddows Brumm, Fancy Border Radius, Glow Generator, Clothoid Corners, Glassmorphism, Clipy, CSS Filters, Base64 Image, Quantity Queries, Animations, Cubic-Bezier, Keyframes, Wait Animate, Transition.Style, graphic design, web design, website design, website builder, web developer, web designer, webdesign, ecommerce website, web design company, website creator, website designer, responsive web design, web development company, best website design, web design software, web page design, build a website, web developer salary, design website, web design courses, how to design a website, web design inspiration, website layout, web designer salary, web application development, ecommerce website design, web agency, software development company, web design tutorial, web programming, design company, website design templates, what is web designing, web developer jobs, website developer, web design agency, freelance web developer, web design services, freelance web designer, graphic design websites, web solutions, ecommerce website development, free website design, web development courses, webdev, web developers, web development tools, website design services, developpeur web, web design london, website design ideas, web designing and programming, design a website, web design and development, web dev, web development services, homepage design, best designed websites, cheap website design, learn web design, web design templates, web design tools, web design jobs, website design inspiration, web design india, flash website, website developers, designer websites, website services, website design cost, good website design, site design, simple website design, cool website designs, modern website design, graphic designer websites, webcode, best web design software, website making, free web design software, mobile website design, learn web development, front end web developer, how to become a web developer, web developer portfolio, web development company in india, python web development, web development tutorial, website company, website design and development, web company, webdesigning, professional website design, affordable web design, best web design company, creative web design, top website designs, website design pricing, web developer tools, how to develop a website