Add an ability to perform both a rebase --svn AND THEN an IMMEDIATE update operation, after pull
Created originally on Bitbucket by TimVargo (Tim Vargo)
I propose adding a new mode for postpull: "rebase--svn-then-update". This would be useful only to users of the hgsubversion extension, or any other extension that attempts to bridge Mercurial to an SVN repo.
I have several times now corrupted my local hgsubversion repo, because I failed to follow the proper workflow; but currently the Thg options do not allow me to automate that proper workflow. There is already a postpull mode of "rebase --svn" which helps tremendously, but this alone stops just short of what is truly needed. Users of the hgsubversion extension should always follow every pull operation (which always creates a new branch) with a rebase --svn operation to 'pseudo-merge' this new branch back with the head, and maintain a linear history. While the rebase --svn operation accomplishes this part very well, the very next thing that is then required is to perform an update operation. Failure to do so before making any modification to a versioned file will create a series of problems, starting with an inability to update if there are uncommited modifications (that you don't wish to discard). To make matters even worse, a very misleading tip will steer the unsuspecting user towards performing an Hg merge operation, which is THE LAST THING THAT SHOULD BE DONE, because this will lead to a corruption of the hgsubversion local repo!
If a new mode for postpull existed which allowed users to automate a "rebase--svn-then-update", said hgsubversion users could avoid a lot of frustration and potential repo corruption. This new mode could provide a lot of relief from the following (but not exhaustive) series of error messages:
-- "not a head revision"
-- "can't find svn parent of a merge revision"
-- "cannot backout a merge changeset"
-- "Outgoing changesets parent is not at subversion HEAD" (once you see this, your local hgsubversion repo is corrupt, and fixing it is very painful)