Show More
@@ -16,7 +16,6 from mercurial.i18n import _ | |||
|
16 | 16 | from mercurial import ( |
|
17 | 17 | cmdutil, |
|
18 | 18 | commands, |
|
19 | pycompat, | |
|
20 | 19 | registrar, |
|
21 | 20 | ) |
|
22 | 21 | |
@@ -66,7 +65,7 def amend(ui, repo, *pats, **opts): | |||
|
66 | 65 | |
|
67 | 66 | See :hg:`help commit` for more details. |
|
68 | 67 | """ |
|
69 |
cmdutil.checknotesize |
|
|
68 | cmdutil.check_note_size(opts) | |
|
70 | 69 | |
|
71 | 70 | with repo.wlock(), repo.lock(): |
|
72 | 71 | if not opts.get('logfile'): |
@@ -153,9 +153,8 def uncommit(ui, repo, *pats, **opts): | |||
|
153 | 153 | If no files are specified, the commit will be pruned, unless --keep is |
|
154 | 154 | given. |
|
155 | 155 | """ |
|
156 | cmdutil.check_note_size(opts) | |
|
156 | 157 | opts = pycompat.byteskwargs(opts) |
|
157 | ||
|
158 | cmdutil.checknotesize(ui, opts) | |
|
159 | 158 | cmdutil.resolvecommitoptions(ui, opts) |
|
160 | 159 | |
|
161 | 160 | with repo.wlock(), repo.lock(): |
@@ -328,10 +328,10 def resolvecommitoptions(ui, opts): | |||
|
328 | 328 | return datemaydiffer |
|
329 | 329 | |
|
330 | 330 | |
|
331 |
def checknotesize( |
|
|
331 | def check_note_size(opts): | |
|
332 | 332 | """make sure note is of valid format""" |
|
333 | 333 | |
|
334 |
note = opts.get( |
|
|
334 | note = opts.get('note') | |
|
335 | 335 | if not note: |
|
336 | 336 | return |
|
337 | 337 |
General Comments 0
You need to be logged in to leave comments.
Login now