mercurial/commands.py
branchstable
changeset 15355 dbdb777502dc
parent 15327 67e92d29ecb5
child 15357 8ec1a2cfd2c0
equal deleted inserted replaced
15354:42630f54e513 15355:dbdb777502dc
   342     ctx = scmutil.revsingle(repo, opts.get('rev'))
   342     ctx = scmutil.revsingle(repo, opts.get('rev'))
   343     if not ctx:
   343     if not ctx:
   344         raise util.Abort(_('no working directory: please specify a revision'))
   344         raise util.Abort(_('no working directory: please specify a revision'))
   345     node = ctx.node()
   345     node = ctx.node()
   346     dest = cmdutil.makefilename(repo, dest, node)
   346     dest = cmdutil.makefilename(repo, dest, node)
   347     if os.path.realpath(dest) == repo.root:
   347     if util.realpath(dest) == repo.root:
   348         raise util.Abort(_('repository root cannot be destination'))
   348         raise util.Abort(_('repository root cannot be destination'))
   349 
   349 
   350     kind = opts.get('type') or archival.guesskind(dest) or 'files'
   350     kind = opts.get('type') or archival.guesskind(dest) or 'files'
   351     prefix = opts.get('prefix')
   351     prefix = opts.get('prefix')
   352 
   352