mercurial/commands.py
changeset 8397 613ac2856535
parent 8387 50b6af595e0c
child 8407 223000a687b0
equal deleted inserted replaced
8396:d7a77ad9bcce 8397:613ac2856535
  2249     ui.status(_('pushing to %s\n') % url.hidepassword(dest))
  2249     ui.status(_('pushing to %s\n') % url.hidepassword(dest))
  2250     if revs:
  2250     if revs:
  2251         revs = [repo.lookup(rev) for rev in revs]
  2251         revs = [repo.lookup(rev) for rev in revs]
  2252     r = repo.push(other, opts.get('force'), revs=revs)
  2252     r = repo.push(other, opts.get('force'), revs=revs)
  2253     return r == 0
  2253     return r == 0
  2254 
       
  2255 def rawcommit(ui, repo, *pats, **opts):
       
  2256     """raw commit interface (DEPRECATED)
       
  2257 
       
  2258     (DEPRECATED)
       
  2259     Lowlevel commit, for use in helper scripts.
       
  2260 
       
  2261     This command is not intended to be used by normal users, as it is
       
  2262     primarily useful for importing from other SCMs.
       
  2263 
       
  2264     This command is now deprecated and will be removed in a future
       
  2265     release, please use debugsetparents and commit instead.
       
  2266     """
       
  2267 
       
  2268     ui.warn(_("(the rawcommit command is deprecated)\n"))
       
  2269 
       
  2270     message = cmdutil.logmessage(opts)
       
  2271 
       
  2272     files = cmdutil.match(repo, pats, opts).files()
       
  2273     if opts.get('files'):
       
  2274         files += open(opts['files']).read().splitlines()
       
  2275 
       
  2276     parents = [repo.lookup(p) for p in opts['parent']]
       
  2277 
       
  2278     try:
       
  2279         repo.rawcommit(files, message, opts['user'], opts['date'], *parents)
       
  2280     except ValueError, inst:
       
  2281         raise util.Abort(str(inst))
       
  2282 
  2254 
  2283 def recover(ui, repo):
  2255 def recover(ui, repo):
  2284     """roll back an interrupted transaction
  2256     """roll back an interrupted transaction
  2285 
  2257 
  2286     Recover from an interrupted commit or pull.
  2258     Recover from an interrupted commit or pull.
  3204     "debugdata": (debugdata, [], _('FILE REV')),
  3176     "debugdata": (debugdata, [], _('FILE REV')),
  3205     "debugfsinfo": (debugfsinfo, [], _('[PATH]')),
  3177     "debugfsinfo": (debugfsinfo, [], _('[PATH]')),
  3206     "debugindex": (debugindex, [], _('FILE')),
  3178     "debugindex": (debugindex, [], _('FILE')),
  3207     "debugindexdot": (debugindexdot, [], _('FILE')),
  3179     "debugindexdot": (debugindexdot, [], _('FILE')),
  3208     "debuginstall": (debuginstall, []),
  3180     "debuginstall": (debuginstall, []),
  3209     "debugrawcommit|rawcommit":
       
  3210         (rawcommit,
       
  3211          [('p', 'parent', [], _('parent')),
       
  3212           ('F', 'files', '', _('file list'))
       
  3213           ] + commitopts + commitopts2,
       
  3214          _('[OPTION]... [FILE]...')),
       
  3215     "debugrebuildstate":
  3181     "debugrebuildstate":
  3216         (debugrebuildstate,
  3182         (debugrebuildstate,
  3217          [('r', 'rev', '', _('revision to rebuild to'))],
  3183          [('r', 'rev', '', _('revision to rebuild to'))],
  3218          _('[-r REV] [REV]')),
  3184          _('[-r REV] [REV]')),
  3219     "debugrename":
  3185     "debugrename":