# HG changeset patch # User Augie Fackler # Date 1648222392 14400 # Node ID 533820f5b997735e3e78e67f744a38ef8c08a5db # Parent 9dfbea54b680db04fd915b5a372c042b8e294228# Parent 6e7ae547e38d881302bbf7f4ee23253330e8ad45 merge: with stable diff -r 9dfbea54b680 -r 533820f5b997 hgext/uncommit.py --- a/hgext/uncommit.py Thu Mar 17 11:19:06 2022 -0700 +++ b/hgext/uncommit.py Fri Mar 25 11:33:12 2022 -0400 @@ -273,6 +273,15 @@ if len(curctx.parents()) > 1: raise error.InputError(_(b"cannot unamend merge changeset")) + expected_keys = (b'amend_source', b'unamend_source') + if not any(key in curctx.extra() for key in expected_keys): + raise error.InputError( + _( + b"working copy parent was not created by 'hg amend' or " + b"'hg unamend'" + ) + ) + # identify the commit to which to unamend markers = list(predecessormarkers(curctx)) if len(markers) != 1: diff -r 9dfbea54b680 -r 533820f5b997 i18n/ja.po --- a/i18n/ja.po Thu Mar 17 11:19:06 2022 -0700 +++ b/i18n/ja.po Fri Mar 25 11:33:12 2022 -0400 @@ -26642,7 +26642,7 @@ msgid "" "``pullbundle``\n" -" When set, the server will check pullbundle.manifest for bundles\n" +" When set, the server will check pullbundles.manifest for bundles\n" " covering the requested heads and common nodes. The first matching\n" " entry will be streamed to the client." msgstr "" diff -r 9dfbea54b680 -r 533820f5b997 i18n/pt_BR.po --- a/i18n/pt_BR.po Thu Mar 17 11:19:06 2022 -0700 +++ b/i18n/pt_BR.po Fri Mar 25 11:33:12 2022 -0400 @@ -27460,12 +27460,12 @@ msgid "" "``pullbundle``\n" -" When set, the server will check pullbundle.manifest for bundles\n" +" When set, the server will check pullbundles.manifest for bundles\n" " covering the requested heads and common nodes. The first matching\n" " entry will be streamed to the client." msgstr "" "``pullbundle``\n" -" Se definido, o servidor verificará pullbundle.manifest para\n" +" Se definido, o servidor verificará pullbundles.manifest para\n" " arquivos de bundle que contiverem as cabeças e nós comuns\n" " pedidos. A primeira entrada correspondente será enviadas para\n" " o cliente." diff -r 9dfbea54b680 -r 533820f5b997 mercurial/helptext/config.txt --- a/mercurial/helptext/config.txt Thu Mar 17 11:19:06 2022 -0700 +++ b/mercurial/helptext/config.txt Fri Mar 25 11:33:12 2022 -0400 @@ -2293,7 +2293,7 @@ effectively prevents concurrent pushes. ``pullbundle`` - When set, the server will check pullbundle.manifest for bundles + When set, the server will check pullbundles.manifest for bundles covering the requested heads and common nodes. The first matching entry will be streamed to the client. diff -r 9dfbea54b680 -r 533820f5b997 tests/test-pull-bundle.t --- a/tests/test-pull-bundle.t Thu Mar 17 11:19:06 2022 -0700 +++ b/tests/test-pull-bundle.t Fri Mar 25 11:33:12 2022 -0400 @@ -194,7 +194,7 @@ * sending pullbundle "0.hg" (glob) $ rm repo/.hg/blackbox.log -Test processing when nodes used in the pullbundle.manifest end up being hidden +Test processing when nodes used in the pullbundles.manifest end up being hidden $ hg --repo repo debugobsolete ed1b79f46b9a29f5a6efa59cf12fcfca43bead5a 1 new obsolescence markers diff -r 9dfbea54b680 -r 533820f5b997 tests/test-unamend.t --- a/tests/test-unamend.t Thu Mar 17 11:19:06 2022 -0700 +++ b/tests/test-unamend.t Fri Mar 25 11:33:12 2022 -0400 @@ -39,8 +39,23 @@ Trying to unamend when there was no amend done $ hg unamend + abort: working copy parent was not created by 'hg amend' or 'hg unamend' + [10] + $ echo "bar" >> h + +Trying to unamend when the obsmarker is missing + + $ hg amend + $ hg debugobsolete --delete 0 + deleted 1 obsolescence markers + $ hg unamend abort: changeset must have one predecessor, found 0 predecessors [10] + $ hg strip tip --config extensions.strip= + 0 files updated, 0 files merged, 1 files removed, 0 files unresolved + saved backup bundle to $TESTTMP/repo/.hg/strip-backup/c9fa1a715c1b-06e5c233-backup.hg + $ hg up tip + 1 files updated, 0 files merged, 0 files removed, 0 files unresolved Unamend on clean wdir and tip