A brief list of tips for using git in ATLAS.

Checking out packages

Note that unless you tell it otherwise, git-svn will try and check out the entire history of the project. Not normally a big deal, but since ATLAS uses global revision numbers, there are a lot of commits to look through. git is pretty fast, but you probably don't care about importing the whole history. It is a good idea to try and find a recent commit in your package (e.g. using the websvn log) and tell git to clone from there.

For example, to get Control/AthenaMonitoring from revision 250000:

cd $TestArea
mkdir -p Control
cd Control
git svn clone $SVNOFF/Control/AthenaMonitoring -s -r 250000:HEAD #avoid checking out everything
now wait ...

Using the repository

Generally use normal git commands, e.g.
  • git commit to commit to current branch
  • git branch to make a new (local) branch
  • git checkout -b to create and switch to it.
  • git log --decorate --graph --all --oneline to see a pretty graph showing where your branches and tags are

However, don't try and dcommit merge commits. Do not use git merge. Only rebase.

Pull SVN updates

Commit locally before you do this (or git stash)! Otherwise you will have an unholy mess to figure out. git svn fetch; git svn rebase

Committing back to SVN

git dcommit #Commits will be copied from those of your local git repository, including messages

Making tags and branches

git svn tag AthenaMonitoring-xx-xx-xx -m "My Tag Message"
git svn branch AthenaMonitoring-xx-xx-xx-branch -m "My Branch Message"

-- PeterOnyisi - 11-Jul-2011

Edit | Attach | Watch | Print version | History: r3 < r2 < r1 | Backlinks | Raw View | WYSIWYG | More topic actions
Topic revision: r3 - 2011-07-11 - PeterWaller
    • Cern Search Icon Cern Search
    • TWiki Search Icon TWiki Search
    • Google Search Icon Google Search

    Main All webs login

This site is powered by the TWiki collaboration platform Powered by PerlCopyright & 2008-2019 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback