To give you an idea of how branching and merging works, we will walk through a simple example that uses multiple branches. Our example is a simple project containing "hello world" programs that simply print Hello World! on the console, implemented in different languages.
Given a stable branch called
trunk, we will create a branch to work on a new feature, and before the feature is finished, we will create another branch to fix an urgent bug. Finally, we will merge the
bugfix branch back to the trunk.
In the example steps, we will focus on using the branch operations with basic parameters, the content of the files, and the changes made are not important. In the later sections, we will explain all branch operations in more ...