On 5 Nov 2013 02:03, "Guido van Rossum" <gu...@python.org> wrote:
>
> Two more approaches that can help when you haven't pushed yet:
>
> - hg rollback undoes the most recent local commit while leaving the local
workspace unchanged so the files are now patched but not committed
>
> - hg strip <rev> deletes a revision and all its descendents (requires
some extension to be configured); it also rolls back your workspace so
you'd have to repatch using hg import --no-commit.

A couple more tips:

- I actually have "--no-commit" configured as a standard option for hg
import in my .hgrc file so I never forget

- "hg pull --rebase" avoids having a merge in the history for push races
that involve only default branch changes

- hg histedit is a quite useful extension for adjusting commit history
prior to publication.

(most of the history editing mercurial features require enabling the
appropriate extensions, but it's well worth taking the time to do so - git
users in particular may find that appropriate use of extensions enables a
more familiar local user experience)

Cheers,
Nick.

>
> (BTW everybody here knows you can give hg import a URL straight from
Rietveld's "raw diff download" right?)
>
>
> On Mon, Nov 4, 2013 at 1:04 AM, Oleg Broytman <p...@phdru.name> wrote:
>>
>> Hi!
>>
>> On Mon, Nov 04, 2013 at 03:56:25AM -0500, Terry Reedy <tjre...@udel.edu>
wrote:
>> > The one
>> > thing I tried but could not do was to directly change status 'A'
>> > back to '?'.
>>
>> hg forget file
>>
>> Oleg.
>> --
>>      Oleg Broytman            http://phdru.name/
p...@phdru.name
>>            Programmers don't die, they just GOSUB without RETURN.
>> _______________________________________________
>> Python-Dev mailing list
>> Python-Dev@python.org
>> https://mail.python.org/mailman/listinfo/python-dev
>> Unsubscribe:
https://mail.python.org/mailman/options/python-dev/guido%40python.org
>
>
>
>
> --
> --Guido van Rossum (python.org/~guido)
>
> _______________________________________________
> Python-Dev mailing list
> Python-Dev@python.org
> https://mail.python.org/mailman/listinfo/python-dev
> Unsubscribe:
https://mail.python.org/mailman/options/python-dev/ncoghlan%40gmail.com
>
_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
https://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to