Git

Reference Material

Empty server repo

1
2
mkdir -p $REMOTE_REPO_ABSOLUTE_PATH
git --bare init

Note: somewhere in your home folder is probably best.

First push to empty server repo

1
2
3
4
5
git init
git add .
git commit -a -m "Initial push."
git remote add origin ssh://$SERVER_URL/$REMOTE_REPO_ABSOLUTE_PATH
git push origin master

Ranged cherry pick into branch

1
2
git checkout -b fix644
git rebase -i $COMMIT_ID

Override local changes

1
git reset --hard

Initialise a SVN bridge

1
2
3
4
git svn init -s $REMOTE_REPO .
git svn fetch
git rebase trunk
git svn dcommit

Remote Tracking

1
2
git branch rspec
git branch --track $BRANCH $REMOTE/$BRANCH

Extract zip of branch

1
git archive --format zip --output ${FILE}.zip $BRANCH

tags: [ ]