Skip to content

Commit 8f0abc9

Browse files
Merge pull request mendix#9146 from mendix/revert-9115-kk-peer-review
Revert "Kk peer review"
2 parents 257a8af + 67b6d19 commit 8f0abc9

2 files changed

Lines changed: 89 additions & 117 deletions

File tree

  • content/en/docs
    • refguide9/version-control/using-version-control-in-studio-pro
    • refguide/version-control/using-version-control-in-studio-pro

content/en/docs/refguide/version-control/using-version-control-in-studio-pro/merge-algorithm.md

Lines changed: 21 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -13,31 +13,32 @@ aliases:
1313

1414
## Introduction
1515

16-
While working on your changes you may find that your local copy of the app model does not have all the changes that other team members have [committed](/refguide/commit-dialog/) to the server (the [Mendix Team Server](/developerportal/general/team-server/), or an [on-premises server](/refguide/on-premises-git/)). In Git terminology this is called being behind.
16+
While working on your changes you may find that your local copy of the app model doesn't have all the changes that other team members have [committed](/refguide/commit-dialog/) to the server (the [Mendix Team Server](/developerportal/general/team-server/), or an [on-premises server](/refguide/on-premises-git/)).
17+
In Git terminology this is called 'being behind'.
1718

1819
When this happens, Mendix Studio Pro offers two ways to combine your changes with changes from the server: [Rebase](#rebase) and [Merge commit](#merge).
1920

2021
Both options support the following features when it comes to [resolving the conflicts](#resolve):
2122

22-
* Fine-grained conflict resolution – When there are conflicting changes in a document, you do not have to choose between whole documents, resolving a conflict using your change or using their change. Instead, you can resolve conflicts at the level of individual elements, such as widgets, entities, attributes, or microflow actions. All non-conflicting changes from both sides are accepted automatically.
23-
* No conflicts on changes to lists of widgets – When two developers make changes to widgets in the same document there is no conflict, the changes are combined. However, if the changes are made too close to the same place in the document, a list order conflict is reported that reminds the developer who is merging the changes to decide on the final order of the widgets in the list.
24-
* They can be aborted at any time. Studio Pro will continue from your latest local commit.
23+
* **Fine-grained conflict resolution** – When there are conflicting changes in a document, you do not have to choose between whole documents, resolving a conflict using your change or using their change. Instead, you can resolve conflicts at the level of individual elements, such as widgets, entities, attributes, or microflow actions. All non-conflicting changes from both sides are accepted automatically.
24+
* **No conflicts on changes to lists of widgets** – When two developers make changes to widgets in the same document there is no conflict, the changes are combined. However, if the changes are made too close to the same place in the document, a **list order conflict** is reported that reminds the developer who is merging the changes to decide on the final order of the widgets in the list.
25+
* Can be aborted at any time. Studio Pro will continue from your latest local commit.
2526

2627
The differences between the two approaches are as follows:
2728

28-
* Rebase (default):
29-
* Treats changes from the server as leading, by first retrieving the server state, and then reapplying your work to it.
29+
* Rebase (*default*):
30+
* Treats changes from the server as leading, by first retrieving the server state and then reapplying your work to it.
3031
* Results in a simple commit history.
31-
* Resolves conflicts when reapplying your local commits. If you have three local commits, this could trigger conflict resolution three times.
32+
* Resolves conflicts when reapplying your local commits. If you have 3 local commits, this could trigger conflict resolution 3 times.
3233
* Merge commit:
33-
* Treats local and remote changes equally, and combines them in a separate merge commit.
34+
* Treats local and remote changes equally, and combines them in a separate 'merge commit'.
3435
* Results in a more complicated commit history with extra merge commits.
3536
* Resolves conflicts once, regardless of the number of local and remote commits being merged.
3637

3738
{{% alert color="info" %}}
3839
In general, Mendix recommends using the Rebase strategy when combining changes, especially when actively collaborating on the same branch.
3940

40-
In exceptional cases, for example when you have a lot of local commits where you expect conflicts, a merge commit may be the better choice.
41+
In exceptional cases, for example when you have a lot of local commits where you expect conflicts, a merge commit might be the better choice.
4142
{{% /alert %}}
4243

4344
Both processes are guided by [notification controls](#notifications) showing the actual state and possible next steps.
@@ -48,36 +49,33 @@ The clearest way to explain and illustrate the differences between Rebase and Me
4849

4950
### Starting Point
5051

51-
To start this scenario, let us assume that you have added the following entities to the domain model of your project:
52+
There are two entities `User` and `Game` which you have added to the domain model of your project.
5253

53-
* `User`
54-
* `Game`
55-
56-
The User entity includes the string attributes `E_mail` and `Second_E_mail`.
54+
The User entity includes string attributes `E_mail` and `Second_E_mail`.
5755

5856
{{< figure src="/attachments/refguide/version-control/using-version-control-in-studio-pro/merge-algorithm/DomainModel/Starting_State.png" >}}
5957

60-
### Your Local Changes
58+
### Local Changes, Your Work
6159

62-
During your work you make the following changes, each one in separate commit:
60+
During your work you make two changes, each one in separate commit.
6361

64-
* Rename `E_mail` to `Email`.
62+
In the first commit you rename `E_mail` to `Email`
6563

66-
{{< figure src="/attachments/refguide/version-control/using-version-control-in-studio-pro/merge-algorithm/DomainModel/First_Local_Commit.png" >}}
64+
{{< figure src="/attachments/refguide/version-control/using-version-control-in-studio-pro/merge-algorithm/DomainModel/First_Local_Commit.png" >}}
6765

68-
* Rename `Second_E_mail` to `Second_Email`.
66+
In the next commit you rename `Second_E_mail` to `Second_Email` to be consistent with previous change.
6967

70-
{{< figure src="/attachments/refguide/version-control/using-version-control-in-studio-pro/merge-algorithm/DomainModel/Second_Local_Commit.png" >}}
68+
{{< figure src="/attachments/refguide/version-control/using-version-control-in-studio-pro/merge-algorithm/DomainModel/Second_Local_Commit.png" >}}
7169

72-
### Another User's Changes
70+
### Server Changes
7371

74-
In the meantime, your colleague also decided to make changes to both email fields. They have renamed `E_mail` to `EmailAddress` and removed `Second_E_mail` entirely. They have then pushed their changes to the server.
72+
In the meantime, your colleague also decided to make some changes to both email fields. They have renamed `E_mail` to `EmailAddress` and removed `Second_E_mail` entirely. These changes have been pushed to the server.
7573

7674
{{< figure src="/attachments/refguide/version-control/using-version-control-in-studio-pro/merge-algorithm/DomainModel/Remote_State.png" >}}
7775

7876
### Summary
7977

80-
The current situation could be represented as shown below.
78+
The current situation could be represent as shown below.
8179

8280
{{< figure src="/attachments/refguide/version-control/using-version-control-in-studio-pro/merge-algorithm/Steps/Rebase_Starting_state.png" alt="Team Server with three commits (1, 2, and 4), while in Studio Pro there are also three commits (1, 3, and 5)" width="525" >}}
8381

0 commit comments

Comments
 (0)