ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Help / Developing an application or website / Source Code Manager (SCM) / Managing branches
  • Principle
  • Merge window
  • Initial display
  • Conflict of code changes
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Others
Stored procedures
Principle
Branches allow you to simultaneously manage several versions of the same application.
Here is a common scenario:
  • You have deployed a version of your application and you are working on the next version.
  • However, you also want to deploy bug fixes from the new version to the release version, and thus create and distribute intermediate versions.
Branches are usually represented on a timeline.
Example:
In this example, there is a main branch (named "My Version") from which a "Version 1" branch has been created. The origin is the state of the project at the time the branch was created. This origin is noted in the branch: it will later allow an automatic merge.
In our example, changes have been made both in the main branch and in the "Version 1" branch. We want to reintegrate all the modifications of the main branch into "Version 1" by merging branches.
To perform this merge, three elements will be compared:
  • The state of the project at the time the branch was created (origin).
  • The current state of the main branch ("My Version").
  • The current state of the "Version 1" branch.
By comparing the files in these three states, it is possible to calculate a merge of the two branches.
This merge is then reintegrated into the "Version 1" branch. Since the branches are now merged, the time of merging becomes the new origin that will be used for the next merge if necessary.
Merge window

Initial display

The merge window only appears when a conflict appears. This window shows the three moments of comparison.
For each element:
  • the "Current project" column shows the status of the element in the project currently open in the editor.
  • the "Changes to propagate" column shows the status of the element in the branch.
By default, this window prompts you to retrieve the element from the branch. For example, if the element does not exist in the current project, but does exist in the branch, it will be suggested in the merge result.
You can choose the elements to be taken into account in the merge for each element: just click on the table cells that correspond to the version to be taken into account for the merge.
Remark: The " Complete view (show all the differences with origin) " option also allows you to view the differences with the original version, i.e. when the branch was created.

Conflict of code changes

When a code conflict is detected, the "Code differences" link appears in the merge window. This link displays the merge window for differences in the code.
This window is divided into three parts:
  • the "Current project" column: shows the code in the project currently open in the editor.
  • the "Result" column: corresponds to the merged code that will be used.
  • the "Changes to propagate" column shows the code used in the branch.
In this window, just use the arrow buttons to merge the code into the result area.
Remark: the option "View original version" allows you to add a fourth column corresponding to the code of the original version.
Minimum version required
  • Version 23
This page is also available for…
Comments
Click [Add] to post a comment

Last update: 05/03/2023

Send a report | Local help