Sheriffing/How To/Unified Repos: Difference between revisions

Jump to navigation Jump to search
default to histedit to correct repository and use hg strip -r . to remove merge commits
m (Drop references to fx-team)
(default to histedit to correct repository and use hg strip -r . to remove merge commits)
Line 184: Line 184:


== Recovering from mistakes ==
== Recovering from mistakes ==
<big>WARNING:</big> This will strip out any commits that haven't been pushed to the remote repositories, regardless of what branch/label/tag those commits are on. (So if you have local changes on inbound and run this command to strip something bad on autoland, both inbound and autoland will be stripped.) Only do this if you don't care about any of those commits!
The histedit subcommand of hg lets you remove, edit and reorder changesets (in addition to other actions):
* hg strip 'not public()'
* hg histedit
If a merge commit needs to be removed:
hg strip --no-backup -r .
<big>WARNING:</big> The hg strip command below removes any commits that haven't been pushed to the remote repositories, regardless of what branch/label/tag those commits are on. (So if you have local changes as patches for other issues - even based on other trees - they will be removed.) Only do this if you don't care about any of those commits!
* hg strip --no-backup 'not public()'
 


You may also need to use some combination of the following to get things back to a known-good state:
You may also need to use some combination of the following to get things back to a known-good state:
Confirmed users
571

edits

Navigation menu