Practical rebase for HG
Simon King
simon at simonking.org.uk
Thu Aug 21 11:14:24 UTC 2014
On Thu, Aug 21, 2014 at 7:16 AM, anatoly techtonik <techtonik at gmail.com> wrote:
> Rebase is useful for reviews. Right now if you update PR, you need
> to the following:
>
> $ hg log --graph --limit 10
> $ hg rebase
> $ hg phase -d -r <start>:<end> -f
> $ hg rebase
>
> Then go to Bitbucket -> Admin ->Strip.
>
> $ hg push
>
>
> Putting aside inevitable BB Admin mess, how do you find the start
> and end commits in a single lineage? In the most simple form I need
> to make all outgoing commits as drafts, in most complicated only
> from the single lineage.
I'm not sure I fully understand the question, but having to force
changesets back to draft status is not ideal. If possible, I would
recommend doing reviews in a non-publishing repository (which
bitbucket supports:
https://bitbucket.org/site/master/issue/4560/provide-a-method-for-setting-the-phase-of).
Once you've done that, the commits for your review would be the ones
that are still draft (perhaps filtered according to ancestry if you
are working on multiple PRs in the same repository). Something like
the revset "draft() and ancestors(.)"
Hope that helps,
Simon
More information about the Mercurial
mailing list