Here are some of the git commands that really helps the newbie programmer to get started with Git

1. git config

This command is used to set your name and email in the main configuration file. And It is also helpful to check your name and email Set up your name and email git config-global user.email

2. git init

This command is used to initialize the new and empty repository. And also helps to convert the unversioned and existing project to Git repository, The git init command also known as root command, which is used to run at the beginning of the new or existing project. Because all other git commands are not available to run outside of the initialized repository. git config-global user.email = “your_email_address”

3. git remote

This command is used to check and list the remote/source you have, also it adds the new remote/source repository. Here remote means the place where your code is stored, it is either Github or external server. Check and list the remote repository Adding the new remote URL

4. git clone

This command targets an existing repository and creates its clone, i.e., a copy of existing repository. This copied repository has a different location from existing one, contains it’s own history and manages its own files. Cloning an existing repository

5. git status

This command is helpful to check the status of the working directory. It shows all the changes since the last commit of the working directory. Apply the command inside the working directory and it lists all the files that have changed

6. git add

To the current directory, git add command adds all modified or new or untracked files. And it also adds subdirectories to staging/index area, these directories are included in the next git commit. Using this command you can add files to the staging area

7. git commit

This command promotes your changes and set up the new commit object. This object doesn’t change unless you commit to any changes. Commit your changes to remote

8. git branch

This is a simple command that lists out all the branches. List out branches of the working directory, projects, or staging area To list remote branch use the following

9. git checkout

This command will help to switch between the different branches. Create and switch to a new branch:

10. git reset

This command is a complex and versatile tool. It will help you to undo the changes. or git checkout -b I covered few of the essential commands from git that are helpful for a newbie, If I missed any then go ahead to comment and help others.