You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: content/en/docs/refguide/modeling/menus/version-control-menu/_index.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -49,11 +49,11 @@ The **Merge Changes Here** option allows you to merge changes that were committe
49
49
50
50
## Revert a Commit
51
51
52
-
The **Revert a Commit** option allows locally rolling back changes that were committed to the version control repository. These local changes can then be committed as a new revision.
52
+
The **Reverse Merge Changes** option allows you to locally [roll back changes](/refguide/using-version-control-in-studio-pro/#revert-changes) that were committed to the version control repository. These local changes can then be committed as a new revision.
53
53
54
54
## Revert All Changes {#revert-all-changes}
55
55
56
-
The **Revert All Changes** option allows rolling back all local changes, both in the app and in files on disk, that have been introduced since the last commit.
56
+
The **Revert All Changes** option allows you to [roll back all local changes](/refguide/using-version-control-in-studio-pro/#revert-changes), both in the project and in files on disk, that have been introduced since the last commit.
Copy file name to clipboardExpand all lines: content/en/docs/refguide/version-control/using-version-control-in-studio-pro/_index.md
+32-14Lines changed: 32 additions & 14 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -201,14 +201,44 @@ Select a revision to see additional details, such as related stories, changed do
201
201
202
202
## Reverting Changes {#revert-changes}
203
203
204
-
Changes that have not yet been committed can be reverted. Say, for example, that you have made a lot of changes to a page and you are not happy with the result. You can revert the page to the original state, that is, the state of the page before you started making changes.
204
+
In case you want to undo changes that have been made, it is important to understand the difference between uncommitted changes, and committed changes that have been pushed to the server. Uncommitted work can simply be reverted, while committed work requires a new **Reverse commit** to undo.
205
205
206
-
Deletes of documents, folders, and modules can also be reverted. This brings them back into the app. Note that you will get back the latest version you have committed. For example, if you commit, make some changes to a microflow, and then delete the microflow, reverting the delete gives you the microflow without the changes that you made.
206
+
### Reverting Uncommitted Changes
207
+
208
+
Changes that have not yet been committed can be reverted. For example, that you have made a lot of changes to a page and you are not happy with the result. You can revert the page to the original state, that is, the state of the page before you started making changes.
209
+
210
+
Deletes of documents, folders, and modules can also be reverted. This brings them back into the app. Note that you will get back the latest version you have committed. For example, if you commit, make some changes to a microflow, and then delete the microflow, reverting the delete restores the microflow without the changes that you made.
207
211
208
212
You can revert changes in the **Changes** pane, from **Version Control** > **Revert All Changes**, or from the right-click menu on the document you want to revert.
209
213
210
214
{{< figure src="/attachments/refguide/version-control/using-version-control-in-studio-pro/revertx2.png" alt="Two ways of reverting" class="no-border" >}}
211
215
216
+
{{% alert color="info" %}}
217
+
You can also **Revert All Changes** while [merging](#merge). This will restore your app to the most recent commit, discarding changes creating by the merging process.
218
+
{{% /alert %}}
219
+
220
+
### Reverting a Previous Commit
221
+
222
+
Changes that have been committed and pushed to the server can never be deleted from the history. However, you can make another commit to revert the changes. This is called **Reverse commit** in Studio Pro.
223
+
224
+
Select the **Version Control** menu > **Revert a Commit...** to revert a commit. This will create original changes "in reverse", which you can commit and push to the server.
225
+
226
+
{{% alert color="warning" %}}
227
+
Reverting a commit creates a new commit that undoes the changes introduced by the original commit. This may lead to unexpected results depending on the context of the original commit.
228
+
***Port fix and reverting** – If you used [Port Fix](/refguide/merge-dialog/#port-fix) to apply a commit from another branch to the current branch, and then you revert that commit, the changes from the cherry-pick will not be reapplied when merging the full branch. This happens because the revert commit explicitly negates the cherry-picked changes, and Git recognizes them as already addressed.
229
+
***Merging and reverting** – If you [merged another branch](/refguide/version-control/#merging-branches) into the current branch and then reverted the merge commit, merging the same branch again will not reapply its changes. Git identifies that the merge was undone and prevents those changes from being reapplied.
230
+
{{% /alert %}}
231
+
232
+
Reverting changes is done with one commit at a time. If you want to revert multiple commits, you can do that by reverting the latest commit, then the previous one, etc, one by one.
You can also revert a commit where another branch was merged into the current branch. Reverting a merge removes the changes introduced by that merge, making it appear as if they never happened. For example, if the merge added a new page, reverting it will remove the page locally.
239
+
240
+
Just like with a normal merge, conflicts can occur when reverting a merge. For example, if later commits change the new page, the reverse merge will result in a conflict. Once you resolved the conflict, you can commit the changes and push them to the remote repository.
241
+
212
242
## Dealing With Conflicts {#conflicts}
213
243
214
244
If you update/pull your app and the changes cannot be merged automatically, you will receive a message telling you that there are conflicts. A conflict arises when two changes cannot be combined.
@@ -276,18 +306,6 @@ Merging is always done while you have a working copy open. The merge will result
276
306
277
307
Select **Version Control** > **Merge Changes Here**, after that you can select **Port fix** or **Merge feature branch** options. For more information on merge settings, see [Merge Dialog](/refguide/merge-dialog/).
278
308
279
-
#### Reverting a Commit
280
-
281
-
[Reverting changes](#revert-changes) works for changes that have not been committed yet. Changes that have been committed and pushed to the server can never be deleted from the history. However, you can make another commit to revert the changes. This feature is called **Reverse commit** in Studio Pro.
282
-
283
-
Choose the **Version Control** menu > **Revert a Commit...** to revert a commit.
284
-
285
-
Reverting changes is done with one commit at a time. If you want to revert multiple commits, you can do that by reverting the latest commit, then the previous one, only one by one.
After a reverse merge the app will look like the changes never happened; if you reverse merge adding a new page, the page will be deleted locally. Just like when you are doing a normal merge, conflicts can arise. For example, if later commits change the new page, the reverse merge will result in a conflict. After resolving the conflict, you can commit and push the results to the remote repository.
290
-
291
309
#### Replacing the Main Line with a Branch Line
292
310
293
311
There are two methods for fully replacing your main line with a branch line.
0 commit comments