GIt contains 2 types of repositories:
1) Local Repository
2) Remote Repository
For every developer, a separate local repository is available. Developer can perform all
checkout and commit operations wrt local repository only.
To perform commit operation, first he has to add files to staging area by using git add
command, and then he has to commit those changes to the local repository by using git
commit command. Hence commit in GIT is a 2-step process.
commit is applicable only for staging area files but not for working directory files.
If the developer wants to share his work to the peer developers then he has to push his
local repository to the remote repository by using git push command.
Remote repository contains total project code, which can be accessible by all developers.
New developer can get local repository by cloning remote repository.For this we have to
use git clone command.
A developer can get updates from the remote repository to the local repository by using
git pull command.