|
|
On this page we will describe how to use Git to update your local files, make new branches and push changes to the remote repository. We assume that you have cloned the OpenSimRoot repository and have added the remote repository under the name "origin". See https://gitlab.com/rootmodels/OpenSimRoot/wikis/get-started-via-the-terminal-on-linux if you're unsure if this is the case.
|
|
|
|
|
|
First of all, if you need to refresh your knowledge of Git, it's advisable to check out this short introduction: https://speakerdeck.com/alicebartlett/git-for-humans.
|
|
|
|
|
|
Git keeps track of all the changes that are made to code and provides useful tools that allow multiple people to work on the same project simultaneously. This is usually done using branches. The main version of the code is called the master branch. Think of each other branch as a copy of the code that differs slightly from the code in the master branch. Usually someone will work on a branch until the code is satisfactory and then send a merge request. Then the changes will be reviewed and, if appropriate, merged with the main branch. It is also possible to work in a different 'fork'. Different forks act more like separate copies of the project, while branches are part of the original project. For more, see: http://stackoverflow.com/a/13403195
|
|
|
|
|
|
Before we start, a useful command is: `git status`. With this command git will tell us on which branch we are and if there are any changes we have made that have not been staged for commit yet.
|
... | ... | |