khanchi97 updated this revision to Diff 9348. khanchi97 edited the summary of this revision.
REPOSITORY rHG Mercurial CHANGES SINCE LAST UPDATE https://phab.mercurial-scm.org/D3764?vs=9268&id=9348 REVISION DETAIL https://phab.mercurial-scm.org/D3764 AFFECTED FILES hgext/rebase.py tests/test-rebase-inmemory.t CHANGE DETAILS diff --git a/tests/test-rebase-inmemory.t b/tests/test-rebase-inmemory.t --- a/tests/test-rebase-inmemory.t +++ b/tests/test-rebase-inmemory.t @@ -208,10 +208,11 @@ Check dryrun gives correct results when there is no conflict in rebasing $ hg rebase -s 2 -d 6 -n + starting dry-run rebase; repository will not bechanged rebasing 2:177f92b77385 "c" rebasing 3:055a42cdd887 "d" rebasing 4:e860deea161a "e" - there will be no conflict, you can rebase + dry-run rebase completed successfully; run without -n/--dry-run to perform this rebase $ hg diff $ hg status @@ -240,10 +241,11 @@ Check dryrun working with --collapse when there is no conflict $ hg rebase -s 2 -d 6 -n --collapse + starting dry-run rebase; repository will not bechanged rebasing 2:177f92b77385 "c" rebasing 3:055a42cdd887 "d" rebasing 4:e860deea161a "e" - there will be no conflict, you can rebase + dry-run rebase completed successfully; run without -n/--dry-run to perform this rebase Check dryrun gives correct results when there is conflict in rebasing Make a conflict: @@ -276,6 +278,7 @@ a $ hg rebase -s 2 -d 7 -n + starting dry-run rebase; repository will not bechanged rebasing 2:177f92b77385 "c" rebasing 3:055a42cdd887 "d" rebasing 4:e860deea161a "e" @@ -311,6 +314,7 @@ Check dryrun working with --collapse when there is conflicts $ hg rebase -s 2 -d 7 -n --collapse + starting dry-run rebase; repository will not bechanged rebasing 2:177f92b77385 "c" rebasing 3:055a42cdd887 "d" rebasing 4:e860deea161a "e" diff --git a/hgext/rebase.py b/hgext/rebase.py --- a/hgext/rebase.py +++ b/hgext/rebase.py @@ -820,14 +820,18 @@ if dryrun: rbsrt = rebaseruntime(repo, ui, inmemory, opts) + ui.status(_('starting dry-run rebase; repository will not be' + 'changed\n')) + with repo.wlock(), repo.lock(): try: _dryrunrebase(ui, repo, rbsrt, **opts) except error.InMemoryMergeConflictsError: ui.status(_('hit a merge conflict\n')) return 1 else: - ui.status(_('there will be no conflict, you can rebase\n')) + ui.status(_('dry-run rebase completed successfully; run without' + ' -n/--dry-run to perform this rebase\n')) return 0 finally: # no need to store back in case of dry-run To: khanchi97, #hg-reviewers Cc: indygreg, pulkit, mercurial-devel _______________________________________________ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel