Git Commands Part -2

Girija Viswanathan
3 min readNov 21, 2020

This is the continuation of the my previous blog. Please feel free to have a look at my previous blog here, general introduction on the same.

Common Git Commands

git pull

This command incorporates changes from a remote repository into the current branch. In its default mode, git pull is shorthand for git fetch followed by git merge FETCH_HEAD.

The git pull command is used to fetch and download content from a remote repository and immediately update the local repository to match that content. Merging remote upstream changes into your local repository is a common task in Git-based collaboration work flows.

git push

This command updates remote refs using local refs, while sending objects necessary to complete the given refs.The git push command is used to upload local repository content to a remote repository.

git push <remote> <branch>

Push the specified branch to the remote, along with all of the necessary commits and internal objects. This creates a local branch in the destination repository. To prevent you from overwriting commits, Git won’t let you…

--

--