I am currently learning to use Git, as it is required for a project I will be managing in the future.
I was hoping to be able to have branches in the repository, so that when somebody clones it, they will have those branches ready for use in their local clone. Now it seems like branching is something you can only do client-side, so I was wondering what the alternative is to this. I want to do this because testing needs to be done on the server, which has the test database and other dependencies on it.
(If relevant: I am using Gitolite on an Ubuntu 12.04 server.)
They will have the branches ready (declared as "remote" in your cloned repo), but by default, a clone only checkouts (makes) one local branch.
You would need to declare local branches for all the remote branches, if you really needed to work on all of those (as in "Track all remote git branches as local branches").
So again, when you clone a repo, you get the full history of that repo, including all branches that were pushed to that upstream repo.
As explained in "Set up git to pull and push all branches", you always fetch (or clone) all branches, but you don't always push all branches.
That means you need to think about the branch you want to push, if you want your collaborators to find said branches in their own local repo when they clone your repo.
And one last comment: this isn't related to gitolite, which is an authorization layer.
See "How do programs like gitolite work?"