Basic Commands For Git That Everyone Should Know

Basic Commands For Git That Everyone Should Know

Table of contents

Before starting the command's section, lets see how we can installl git in our local or VM's:

Installing Git on Windows

Step 2: You will view the below screen. Download has started and the .exe file is downloading.

Step 3: Click on Next when this popup window opens.

Step 4: Check the below options and click Next.

Step 5: The below screen comes. Click Next.

Step 6: Choose the appropriate option and click Next.

Step 7: Choose the library option and click on Next.

Step 8: Choose the checkout option and click Next.

step 9: Choose the emulator and click Next.

Step 10: Choose configuration options and click on Install.

Step 11: Once the installation completes, the Git GUI opens.

Now, let us open Git Bash and run some Git commands

1. $ git init “[repository-name]”

2. $ git config

3. $ git add . or git add [filename]

4. $ git commit

5. git status

6. git checkout -b [branchname]

7. git log

8. git ls-files –stage

9. git diff

10. git merge


I am Sunil kumar, Please do follow me here and support #devOps #trainwithshubham #github #devopscommunity #devops #cloud #devoparticles #trainwithshubham

Shubham Londhe

sunil kumar

Connect with me over linkedin : linkedin.com/in/sunilkumar2807