Show More
@@ -1026,7 +1026,7 b' class queue(object):' | |||||
1026 | msg: a string or a no-argument function returning a string |
|
1026 | msg: a string or a no-argument function returning a string | |
1027 | """ |
|
1027 | """ | |
1028 | msg = opts.get('msg') |
|
1028 | msg = opts.get('msg') | |
1029 |
edit |
|
1029 | edit = opts.get('edit') | |
1030 | user = opts.get('user') |
|
1030 | user = opts.get('user') | |
1031 | date = opts.get('date') |
|
1031 | date = opts.get('date') | |
1032 | if date: |
|
1032 | if date: | |
@@ -1081,10 +1081,11 b' class queue(object):' | |||||
1081 | p.write("# Date %s %s\n\n" % date) |
|
1081 | p.write("# Date %s %s\n\n" % date) | |
1082 |
|
1082 | |||
1083 | defaultmsg = "[mq]: %s" % patchfn |
|
1083 | defaultmsg = "[mq]: %s" % patchfn | |
1084 |
|
|
1084 | editor = False | |
1085 |
|
|
1085 | if edit: | |
1086 | def desceditor(repo, ctx, subs): |
|
1086 | def desceditor(repo, ctx, subs): | |
1087 |
desc = |
|
1087 | desc = self.ui.edit(ctx.description() + "\n", | |
|
1088 | ctx.user()) | |||
1088 | if desc.rstrip(): |
|
1089 | if desc.rstrip(): | |
1089 | return desc |
|
1090 | return desc | |
1090 | else: |
|
1091 | else: | |
@@ -2442,10 +2443,6 b' def new(ui, repo, patch, *args, **opts):' | |||||
2442 | msg = cmdutil.logmessage(ui, opts) |
|
2443 | msg = cmdutil.logmessage(ui, opts) | |
2443 | q = repo.mq |
|
2444 | q = repo.mq | |
2444 | opts['msg'] = msg |
|
2445 | opts['msg'] = msg | |
2445 | if opts.get('edit'): |
|
|||
2446 | def editor(repo, ctx, subs): |
|
|||
2447 | return ui.edit(ctx.description() + "\n", ctx.user()) |
|
|||
2448 | opts['editor'] = editor |
|
|||
2449 | setupheaderopts(ui, opts) |
|
2446 | setupheaderopts(ui, opts) | |
2450 | q.new(repo, patch, *args, **opts) |
|
2447 | q.new(repo, patch, *args, **opts) | |
2451 | q.savedirty() |
|
2448 | q.savedirty() |
General Comments 0
You need to be logged in to leave comments.
Login now