##// END OF EJS Templates
Uniformisation of commit help for -m and -l....
Mathieu Clabaut -
r3857:f6f16f87 default
parent child Browse files
Show More
@@ -2103,9 +2103,8 b' cmdtable = {'
2103 2103 'qfold':
2104 2104 (fold,
2105 2105 [('e', 'edit', None, _('edit patch header')),
2106 ('k', 'keep', None, _('keep folded patch files')),
2107 ('m', 'message', '', _('set patch header to <text>')),
2108 ('l', 'logfile', '', _('set patch header to contents of <file>'))],
2106 ('k', 'keep', None, _('keep folded patch files'))
2107 ] + commands.commitopts,
2109 2108 'hg qfold [-e] [-m <text>] [-l <file] PATCH...'),
2110 2109 'qguard': (guard, [('l', 'list', None, _('list all patches and guards')),
2111 2110 ('n', 'none', None, _('drop all guards'))],
@@ -2127,9 +2126,8 b' cmdtable = {'
2127 2126 "qnew":
2128 2127 (new,
2129 2128 [('e', 'edit', None, _('edit commit message')),
2130 ('m', 'message', '', _('use <text> as commit message')),
2131 ('l', 'logfile', '', _('read the commit message from <file>')),
2132 ('f', 'force', None, _('import uncommitted changes into patch'))],
2129 ('f', 'force', None, _('import uncommitted changes into patch'))
2130 ] + commands.commitopts,
2133 2131 'hg qnew [-e] [-m TEXT] [-l FILE] [-f] PATCH'),
2134 2132 "qnext": (next, [] + seriesopts, 'hg qnext [-s]'),
2135 2133 "qprev": (prev, [] + seriesopts, 'hg qprev [-s]'),
@@ -2150,12 +2148,11 b' cmdtable = {'
2150 2148 "^qrefresh":
2151 2149 (refresh,
2152 2150 [('e', 'edit', None, _('edit commit message')),
2153 ('m', 'message', '', _('change commit message to <text>')),
2154 ('l', 'logfile', '', _('change commit message to <file> content')),
2155 2151 ('g', 'git', None, _('use git extended diff format')),
2156 2152 ('s', 'short', None, 'refresh only files already in the patch'),
2157 2153 ('I', 'include', [], _('include names matching the given patterns')),
2158 ('X', 'exclude', [], _('exclude names matching the given patterns'))],
2154 ('X', 'exclude', [], _('exclude names matching the given patterns'))
2155 ] + commands.commitopts,
2159 2156 'hg qrefresh [-I] [-X] [-e] [-m TEXT] [-l FILE] [-s] FILES...'),
2160 2157 'qrename|qmv':
2161 2158 (rename, [], 'hg qrename PATCH1 [PATCH2]'),
@@ -2166,12 +2163,10 b' cmdtable = {'
2166 2163 'hg qrestore [-d] [-u] REV'),
2167 2164 "qsave":
2168 2165 (save,
2169 [('m', 'message', '', _('use <text> as commit message')),
2170 ('l', 'logfile', '', _('read the commit message from <file>')),
2171 ('c', 'copy', None, 'copy patch directory'),
2166 [('c', 'copy', None, 'copy patch directory'),
2172 2167 ('n', 'name', '', 'copy directory name'),
2173 2168 ('e', 'empty', None, 'clear queue status file'),
2174 ('f', 'force', None, 'force copy')],
2169 ('f', 'force', None, 'force copy')] + commands.commitopts,
2175 2170 'hg qsave [-m TEXT] [-l FILE] [-c] [-n NAME] [-e] [-f]'),
2176 2171 "qselect": (select,
2177 2172 [('n', 'none', None, _('disable all guards')),
@@ -1492,9 +1492,10 b' def import_(ui, repo, patch1, *patches, '
1492 1492 raise util.Abort(_('no diffs found'))
1493 1493
1494 1494 try:
1495 if opts['message']:
1495 cmdline_message = logmessage(opts)
1496 if cmdline_message:
1496 1497 # pickup the cmdline msg
1497 message = opts['message']
1498 message = cmdline_message
1498 1499 elif message:
1499 1500 # pickup the patch msg
1500 1501 message = message.strip()
@@ -2586,6 +2587,11 b' walkopts = ['
2586 2587 ('X', 'exclude', [], _('exclude names matching the given patterns')),
2587 2588 ]
2588 2589
2590 commitopts = [
2591 ('m', 'message', '', _('use <text> as commit message')),
2592 ('l', 'logfile', '', _('read commit message from <file>')),
2593 ]
2594
2589 2595 table = {
2590 2596 "^add": (add, walkopts + dryrunopts, _('hg add [OPTION]... [FILE]...')),
2591 2597 "addremove":
@@ -2617,12 +2623,10 b' table = {'
2617 2623 (backout,
2618 2624 [('', 'merge', None,
2619 2625 _('merge with old dirstate parent after backout')),
2620 ('m', 'message', '', _('use <text> as commit message')),
2621 ('l', 'logfile', '', _('read commit message from <file>')),
2622 2626 ('d', 'date', '', _('record datecode as commit date')),
2623 2627 ('', 'parent', '', _('parent to choose when backing out merge')),
2624 2628 ('u', 'user', '', _('record user as committer')),
2625 ] + walkopts,
2629 ] + walkopts + commitopts,
2626 2630 _('hg backout [OPTION]... REV')),
2627 2631 "branch": (branch, [], _('hg branch [NAME]')),
2628 2632 "branches": (branches, [], _('hg branches')),
@@ -2656,11 +2660,9 b' table = {'
2656 2660 (commit,
2657 2661 [('A', 'addremove', None,
2658 2662 _('mark new/missing files as added/removed before committing')),
2659 ('m', 'message', '', _('use <text> as commit message')),
2660 ('l', 'logfile', '', _('read the commit message from <file>')),
2661 2663 ('d', 'date', '', _('record datecode as commit date')),
2662 2664 ('u', 'user', '', _('record user as commiter')),
2663 ] + walkopts,
2665 ] + walkopts + commitopts,
2664 2666 _('hg commit [OPTION]... [FILE]...')),
2665 2667 "copy|cp":
2666 2668 (copy,
@@ -2743,10 +2745,9 b' table = {'
2743 2745 [('p', 'strip', 1,
2744 2746 _('directory strip option for patch. This has the same\n'
2745 2747 'meaning as the corresponding patch option')),
2746 ('m', 'message', '', _('use <text> as commit message')),
2747 2748 ('b', 'base', '', _('base path (DEPRECATED)')),
2748 2749 ('f', 'force', None,
2749 _('skip check for outstanding uncommitted changes'))],
2750 _('skip check for outstanding uncommitted changes'))] + commitopts,
2750 2751 _('hg import [-p NUM] [-m MESSAGE] [-f] PATCH...')),
2751 2752 "incoming|in": (incoming,
2752 2753 [('M', 'no-merges', None, _('do not show merges')),
@@ -2838,9 +2839,8 b' table = {'
2838 2839 [('p', 'parent', [], _('parent')),
2839 2840 ('d', 'date', '', _('date code')),
2840 2841 ('u', 'user', '', _('user')),
2841 ('F', 'files', '', _('file list')),
2842 ('m', 'message', '', _('commit message')),
2843 ('l', 'logfile', '', _('commit message file'))],
2842 ('F', 'files', '', _('file list'))
2843 ] + commitopts,
2844 2844 _('hg debugrawcommit [OPTION]... [FILE]...')),
2845 2845 "recover": (recover, [], _('hg recover')),
2846 2846 "^remove|rm":
General Comments 0
You need to be logged in to leave comments. Login now