How to download the different branches
What are the different development and release branches of FOG and how does one download each?
Wayne Workman last edited by
Looks like you mean to say the following to list available branches:
git branch -a
Thank you for the update regarding the SVN repository’s repurposing. This is all good to know.
Wayne Workman last edited by Wayne Workman
@sudburr tom told me a while back that since 1.3.0 svn is only getting updated with releases.
It doesn’t hurt to know how to use svn, it can be helpful. But I would recommend using git.
You can find lots of info online about subversion (svn).
Thank you for this great info. How about svn or is it not being used anymore?
Branches in GIT allow developers to separate code into elements while leaving other elements alone.
Typical structure for a repo in GIT will have at least 2 branches.
The first branch is typically
master. This is the “top” level branch typically containing the current “stable” software version.
The second branch can be named nearly anything, and essentially would be akin to subversion’s
trunk. Some GIT repos model their repos off of this and have a
trunkbranch. This might be where the next development work is at.
FOG’s structure is:
masterThe current stable release.
dev-branchthe current RC release.
working-1.3.4the development for the 1.3.4 version (currently.
newIpxeGenerationA branch where I’m refactoring ipxe menu generation.
persistentGroupPluginA branch where i am (kind of?) working on a new model to the persistent group sql trigger stuff.
In git you clone a repo with a command like:
git clone https://<url>/<repoowner>/<reponame>[.git]
For fog this would be:
git clone https://github.com/fogproject/fogproject.git(The .git part is optional but normal to add as well.)
This will download whatever is the “default” branch to download. In FOG’s perspective, the default is
You do not need to “clone” the repo every time, it is only needed to initially download the repository information if you have not done so already.
If you’ve already retrieved the repo, you just cd into the base path. More often this might be
Once in the base path you can change branches. To get a list of all branches available you would run
git fetch --all
To view available branches run:
git branchThe one with the * is the branch you’re currently on.
To switch to one branch or another run:
git checkout <branchname>
So to switch from the master to dev-branch in our scenario you would run:
git checkout dev-branch
Hopefully that helps answer that.
As a word of caution I’d also highly recommend always running
git pullwhen you change in and out of branches. This will pull in any new changes.