##// END OF EJS Templates
record: suggest the right command when running non interactively
Idan Kamara -
r14407:51cabd56 default
parent child Browse files
Show More
@@ -368,7 +368,7 b' def record(ui, repo, *pats, **opts):'
368
368
369 This command is not available when committing a merge.'''
369 This command is not available when committing a merge.'''
370
370
371 dorecord(ui, repo, commands.commit, *pats, **opts)
371 dorecord(ui, repo, commands.commit, 'commit', *pats, **opts)
372
372
373
373
374 def qrecord(ui, repo, patch, *pats, **opts):
374 def qrecord(ui, repo, patch, *pats, **opts):
@@ -386,12 +386,13 b' def qrecord(ui, repo, patch, *pats, **op'
386 def committomq(ui, repo, *pats, **opts):
386 def committomq(ui, repo, *pats, **opts):
387 mq.new(ui, repo, patch, *pats, **opts)
387 mq.new(ui, repo, patch, *pats, **opts)
388
388
389 dorecord(ui, repo, committomq, *pats, **opts)
389 dorecord(ui, repo, committomq, 'qnew', *pats, **opts)
390
390
391
391
392 def dorecord(ui, repo, commitfunc, *pats, **opts):
392 def dorecord(ui, repo, commitfunc, cmdsuggest, *pats, **opts):
393 if not ui.interactive():
393 if not ui.interactive():
394 raise util.Abort(_('running non-interactively, use commit instead'))
394 raise util.Abort(_('running non-interactively, use %s instead') %
395 cmdsuggest)
395
396
396 def recordfunc(ui, repo, message, match, opts):
397 def recordfunc(ui, repo, message, match, opts):
397 """This is generic record driver.
398 """This is generic record driver.
General Comments 0
You need to be logged in to leave comments. Login now