git clone ssh://

git pull to get changes

git push to commit changes

commits to svn should only be done from GSI machine

Working with GIT, SVN and gitorious

After i messed up the first version of the git repository due to unresolvable differences between the gitorious repository and the working copy which was used to synchronize git with svn I cam to the conclusion that it is better to use the synchronization repository only for synchronization. In the first version I did also the work (edit, new branches, merges and so on) in this directory. In the following I will document how I setup the second version and how the workflow looks like.

The synchronization repositories between the SVN repository and gitorious@gsi is on demac006 at ~/GIT This directory should be only used to fetch the latest updates from SVN, push them to gitorious and maybe after merging (done from another working directory) fetch the new version from gitorious and dcommit them to SVN. All the other git repositories should be synchronized with the gitorious repository at gsi.

Setup a new git repository on gitorious@GSI

  • Add the gitorious repository as path to push changes

  • Create the gitorious repository by pushing the data
    • git push origin master

Create a new git working directory from gitorious@gsi

  • Create a clone of the gitorious repository

  • Add the gitorious repository as path to push changes (if necessary)

  • Create symbolic links for all the external dependencies (only needed for cbmroot, pandaroot and r3broot). Check on which external directories from fairbase are defined. For all of these directories create symbolic links
    • ln -s ../fairbase/base

  • For cbmroot one has to copy the required fieldmaps to the input directory.

Create a new branch for the development

To make things more easy for later merges it is best to do all the developments in a development branch. If the development is ready to go back to the SVN repository one has to merge the development branch into the master branch.

  • git checkout -b branchname

-- FlorianUhlig - 18 May 2010
Topic revision: r5 - 2011-05-31, FlorianUhlig
This site is powered by FoswikiCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding CBM Wiki? Send feedback
Imprint (in German)
Privacy Policy (in German)