##// END OF EJS Templates
rebase: use cmdutil.command decorator
Adrian Buehlmann -
r14306:db2a8eab default
parent child Browse files
Show More
@@ -24,6 +24,33 b' import os, errno'
24 24
25 25 nullmerge = -2
26 26
27 cmdtable = {}
28 command = cmdutil.command(cmdtable)
29
30 @command('rebase',
31 [('s', 'source', '',
32 _('rebase from the specified changeset'), _('REV')),
33 ('b', 'base', '',
34 _('rebase from the base of the specified changeset '
35 '(up to greatest common ancestor of base and dest)'),
36 _('REV')),
37 ('d', 'dest', '',
38 _('rebase onto the specified changeset'), _('REV')),
39 ('', 'collapse', False, _('collapse the rebased changesets')),
40 ('m', 'message', '',
41 _('use text as collapse commit message'), _('TEXT')),
42 ('l', 'logfile', '',
43 _('read collapse commit message from file'), _('FILE')),
44 ('', 'keep', False, _('keep original changesets')),
45 ('', 'keepbranches', False, _('keep original branch names')),
46 ('', 'detach', False, _('force detaching of source from its original '
47 'branch')),
48 ('t', 'tool', '', _('specify merge tool')),
49 ('c', 'continue', False, _('continue an interrupted rebase')),
50 ('a', 'abort', False, _('abort an interrupted rebase'))] +
51 templateopts,
52 _('hg rebase [-s REV | -b REV] [-d REV] [options]\n'
53 'hg rebase {-a|-c}'))
27 54 def rebase(ui, repo, **opts):
28 55 """move changeset (and descendants) to a different branch
29 56
@@ -558,32 +585,3 b' def uisetup(ui):'
558 585 entry[1].append(('', 'rebase', None,
559 586 _("rebase working directory to branch head"))
560 587 )
561
562 cmdtable = {
563 "rebase":
564 (rebase,
565 [
566 ('s', 'source', '',
567 _('rebase from the specified changeset'), _('REV')),
568 ('b', 'base', '',
569 _('rebase from the base of the specified changeset '
570 '(up to greatest common ancestor of base and dest)'),
571 _('REV')),
572 ('d', 'dest', '',
573 _('rebase onto the specified changeset'), _('REV')),
574 ('', 'collapse', False, _('collapse the rebased changesets')),
575 ('m', 'message', '',
576 _('use text as collapse commit message'), _('TEXT')),
577 ('l', 'logfile', '',
578 _('read collapse commit message from file'), _('FILE')),
579 ('', 'keep', False, _('keep original changesets')),
580 ('', 'keepbranches', False, _('keep original branch names')),
581 ('', 'detach', False, _('force detaching of source from its original '
582 'branch')),
583 ('t', 'tool', '', _('specify merge tool')),
584 ('c', 'continue', False, _('continue an interrupted rebase')),
585 ('a', 'abort', False, _('abort an interrupted rebase'))] +
586 templateopts,
587 _('hg rebase [-s REV | -b REV] [-d REV] [options]\n'
588 'hg rebase {-a|-c}'))
589 }
General Comments 0
You need to be logged in to leave comments. Login now