Using the batman git repositories

If you want to find out why we also have a git repository now, please read here.

Checkout

To retrieve the latest changes you can pull from the read-only http frontend.

git clone http://git.open-mesh.net/batman-adv/ batman-adv-git

There is also a repository for kernel integration. You are about to download 300MB of sources - that may take a while!

git clone http://git.open-mesh.net/ecsv/linux-merge.git/

Branches

The main git repository is divided into several branches to make working easier.

master branch

The master branch is a clone of the batman kernel module SVN found at http://downloads.open-mesh.net/svn/batman/trunk/batman-adv-kernelland/

The idea is that all upcoming changes are built on top of the SVN, so that changes which affect all branches can easily trickle down. A post-commit script makes sure that the SVN is in sync with the git master branch all the time.

In fact you will never work with this branch itself but one of the other branches.

maint branch

The maint is a branch only maintained in git to gather bug fixes for the latest release and well tested features taken from the master branch. Cherry-pick is used to get commits from the master branch and git-am to insert patches from mailboxes.

Create branch associated with the remote-tracking branch after cloning the repository

git checkout -b maint --track origin/maint

Cherry-picking a commit from master branch

git checkout maint
git cherry-pick $SHA1

Linux integration

The linux-merge repository is a clone of Linus Torvalds developer branch. With the help of some git voodoo the maint branch is merged with this branch in the folder: drivers/staging/batman-adv/. If you wish to merge the latest maint branch changes into the linux branch you need to pull the newest changes in maint from the batman-adv-git repository (we assume that you created the maint branch in your local linux-merge repsitory as explained above):

git checkout maint
git pull http://git.open-mesh.net/batman-adv/ maint

and merge the maint branch into this one:

git checkout master
git merge -s subtree maint

If you wish to pull Linus latest changes and merge it you need to add the remote branch first (you can omit that step if you already have it).

git remote add torvalds git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6.git

Fetch its content and merge it:

git checkout master
git fetch torvalds
git merge torvalds/master

To upload your changes you need to run:

git push

difference between maint and linux-integration

If you need to see the difference between the maint branch and the batman-adv driver in drivers/staging/batman-adv/ you can run this command:

git diff maint: linux:drivers/staging/batman-adv/

adding a branch

In case you want to add your own branch for testing purposes or simply wish to understand the magic.

git remote add $remote_name $git_url
git fetch $remote_name

git checkout -b $new_branch_name $remote_name/master
git merge -s ours --no-commit maint
git read-tree --prefix=drivers/staging/batman-adv/ -u maint
git commit -m "Add batman-adv to my new branch"

TODO

We maintain a TODO file in the git repository that you can see here:


Request a review.
Process the comments from the review.
Move into mainline proper.

Please send all patches to:
	Marek Lindner 
	Simon Wunderlich 
	Andrew Lunn 
	b.a.t.m.a.n@lists.open-mesh.net
	Greg Kroah-Hartman 

If you are interested in helping us out you can grab one item, make a patch
and send it to our Mailinglist.