1 # Distributed Source Control Management
3 Unlike SVN, git does not used a central repository. This is why git is "distributed" and SVN is
4 "centralized". Although this makes git an extremely powerful system for collaborators, tracking
5 changes between various collaborators can quickly become difficult as multiple forks are created.
7 Please read the following before working with this code:
9 1. [Dealing with newlines](http://github.com/guides/dealing-with-newlines-in-git)
10 2. [Submitting changes from your fork](http://github.com/guides/fork-a-project-and-submit-your-modifications)
11 3. [Using SSH keys with github](http://github.com/guides/how-to-not-have-to-type-your-password-for-every-push)
13 ## Managing Remote Repositories
15 First, you will need to tell git about the remote repository:
17 git remote add shadowhand git://github.com/shadowhand/kohana.git
19 This adds "shadowhand" as a remote repository that can be pulled from.
21 git checkout -b shadowhand/master
23 This creates a local branch "shadowhand/master" of the master branch of the "shadowhand" repository.
25 ## Merging Changes from Remote Repositories
27 Now that you have a remote repository, you can pull changes into your local repository:
29 git checkout shadowhand/master
31 This switches to the previously created "shadowhand/master" branch.
33 git pull shadowhand master
35 This pulls all of the changes in the remote into the local "shadowhand/master" branch.
39 This switches back to your local master branch.
41 git merge shadowhand/master
43 This merges all of the changes in the "shadowhand/master" branch into your master branch.
47 This pushes all the merged changes into your local fork. At this point, your fork is now in sync
48 with the origin repository!