« Previous -
Version 6/20
(diff) -
Next » -
Current version
Guest User, 10/01/2009 09:14 pm
Added info about local tracking branches (copy from the NewEthMAC page)
Git makes it easier for anyone to develop and contribute code to gnuradio. This article will describe how to use git with multiple repositiories so you can develop and publish your changes to gnuradio. The goal of this page is to help people manage git repositories so code may easily be shared among GNURadio developers.
The basic idea is you clone the gnuradio git repository and maintain a public repository with your work on github, or other public git server.
{{{
$ git config user.name "Your Name"
$ git config user.email [email protected]
}}}
4. Since this is an existing git repo, do the following steps (I called the project gnuradio-balister):
{{{
$ cd gnuradio
$ git remote add balister [email protected]:balister/gnuradio-balister.git
$ git push balister master
}}}
Now you have a local repository and a copy on github so you can publish your work.
To update master on your public repository:
1. {{{$ git pull}}}
2. {{{$ git push balister}}}
Create a local branch, and publish the new work.
1. {{{$ git branch new-work}}}
2. {{{$ git checkout new-work}}}
3. Do some work and commit it.
4. {{{$ git push balister new-work}}}
When you are done with the branch delete it locally, and on the remote repository (if needed):
1. {{{$ git branch new-work -d}}}, maybe use -D if it is not merged.
2. {{{$ git push balister :new-work}}}
If you want to create a local branch tracking a remote branch (e.g. to track a branch on the gnuradio server):
{{{
git branch --track local_new_work origin/new_work
git checkout local_new_work
}}}
Assuming that new_work is a branch on the repository you cloned originally
Please let us know about your repo by emailing {{{[email protected]}}}.