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: work/flow.rst
+9Lines changed: 9 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -553,6 +553,15 @@ If this occurs, the merge may be reverted by anyone who notices the breakage and
553
553
Such a fix need not use a brand new ticket and ticket branch.
554
554
Instead, it can be performed on a "hotfix" branch named after the original ticket that was merged, typically ``tickets/DM-NNNNN-hotfix``.
555
555
556
+
If a merge revert is required, the following process should be followed:
557
+
558
+
- Create a new "revert" branch named ``tickets/DM-NNNNN-revert``. This is necessary because no pushes are allowed directly to the ``main`` branch.
559
+
- Revert the faulty merge commit on the branch. ``git revert -m 1 {merge hash}``. ``-m 1`` indicates that the first parent is the "mainline" code that should be kept.
560
+
- Push the branch, create a PR, and merge it as normal.
561
+
562
+
The commits on the reverted branch cannot be re-merged from that branch as is, even if fixes have been applied.
563
+
The branch should instead be rebased on ``main`` after the revert, according to our normal process.
0 commit comments