Working with remote repository

Author: Al-mamun Sarkar Date: 2020-04-12 14:48:06

Working with remote repository. The following command show how to sync with remote (GitHub, Bitbucket) repository.

 

Download or Pull changes:

git pull

 

Pull a brach:

git pull [remote] [branch_name]

Example:

git pull origin master

 

Push changes:

git push

 

Push to branch:

git push [remote] [branch]

Example:

git push origin master

 

Getting all history from remote repository:

git fetch --all