Game Development Reference
In-Depth Information
Once a repository is cloned, you can right-click it in the client and select either
Open in Explorer or Open in Finder, which will open the directory in which all
the files are stored. You can then open the solution file and edit any files like you
normally would.
When you're ready to commit a change to your local repository, you can double-
click the repository name in the GitHub client to open a more detailed view. In
this view, you will see a list of all the files that have been modified, and can also
expand each entry to see what changes were specifically made to each file. Select
all the files you want to commit and then type in a commit message. Your message
should be as descriptive as possible, because if you type in a generic message, it
makes it a lot harder to immediately determine what changed in a specific commit.
Once you click the commit button, all the selected files will then be committed
to your local repository. However, if you then want to push those changes to the
central repository (if you have permission to do so), you can use the sync button at
the top of the window. This will automatically pull any updates first and then push
your changes. Note that if you don't have permission to push your changes to the
repository, you will get an error message.
The GitHub client does allow you to do other things, too, such as creating a separ-
ate branch. That, combined with the other features, is likely enough for most nor-
mal usage. But in order to perform the more complex operations Git is capable of,
you will have to use another client. One such option is Atlassian SourceTree ( ht-
tp://www.atlassian.com/software/sourcetree/ ), or you can also use Git on the com-
mand line.
Diff and Merging Tools
A diff tool allows you to inspect the differences between two (or more) files.
Manysourcecontrolclientshavethisfunctionalityintegratedinsomeway,suchas
inthecommitwindowintheGitHubclient.Thetraditionaldifftoolwasaprogram
on UNIX that would spit out a text file that documented the differences between
two other text files. Thankfully, more modern tools will actually display differen-
ces side by side in a graphical interface. When used in conjunction with source
control, a diff tool can show you what was specifically changed in a file. One such
open source diff tool is TortoiseMerge, which is included as part of the aforemen-
tioned TortoiseSVN.
A more complex use of such tools is to actually merge changes between multiple
versions. Suppose you are editing GameState.cs, and at the same time another de-
Search WWH ::




Custom Search