Abandoning changes without deleting from history

后端 未结 9 2007
再見小時候
再見小時候 2020-11-28 18:01

There is a commit that just didn\'t work, so I want to abandon it without deleting it from history.

I have updated from an earlier revision and committed, t

9条回答
  •  时光说笑
    2020-11-28 18:30

    You may clone your corrupted repo to a new one without cloning that unwanted head. Then remove old repository, move newly created clone to the original place and continue working with it. This will take some time, but you'll get a perfectly clean repository without a sign of that unwanted revision.

    hg clone --rev myGoodResition myDirtyRepo myCleanRepo
    

提交回复
热议问题