hgext/split.py
changeset 48116 5ced12cfa41b
parent 46924 ca0049946e9a
child 48875 6000f5b25c9b
equal deleted inserted replaced
48115:b067d22dc6ad 48116:5ced12cfa41b
    20     bookmarks,
    20     bookmarks,
    21     cmdutil,
    21     cmdutil,
    22     commands,
    22     commands,
    23     error,
    23     error,
    24     hg,
    24     hg,
       
    25     logcmdutil,
    25     pycompat,
    26     pycompat,
    26     registrar,
    27     registrar,
    27     revsetlang,
    28     revsetlang,
    28     rewriteutil,
    29     rewriteutil,
    29     scmutil,
    30     scmutil,
    73     with repo.wlock(), repo.lock():
    74     with repo.wlock(), repo.lock():
    74         tr = repo.transaction(b'split')
    75         tr = repo.transaction(b'split')
    75         # If the rebase somehow runs into conflicts, make sure
    76         # If the rebase somehow runs into conflicts, make sure
    76         # we close the transaction so the user can continue it.
    77         # we close the transaction so the user can continue it.
    77         with util.acceptintervention(tr):
    78         with util.acceptintervention(tr):
    78             revs = scmutil.revrange(repo, revlist or [b'.'])
    79             revs = logcmdutil.revrange(repo, revlist or [b'.'])
    79             if len(revs) > 1:
    80             if len(revs) > 1:
    80                 raise error.InputError(_(b'cannot split multiple revisions'))
    81                 raise error.InputError(_(b'cannot split multiple revisions'))
    81 
    82 
    82             rev = revs.first()
    83             rev = revs.first()
    83             # Handle nullrev specially here (instead of leaving for precheck()
    84             # Handle nullrev specially here (instead of leaving for precheck()