Mercurial > public > mercurial-scm > hg-stable
diff hgext/fetch.py @ 8407:223000a687b0
commit: move commit editor to cmdutil, pass as function
author | Matt Mackall <mpm@selenic.com> |
---|---|
date | Thu, 14 May 2009 13:20:40 -0500 |
parents | eee2319c5895 |
children | b97e2417ae53 |
line wrap: on
line diff
--- a/hgext/fetch.py Thu May 14 13:20:40 2009 -0500 +++ b/hgext/fetch.py Thu May 14 13:20:40 2009 -0500 @@ -124,10 +124,11 @@ message = (cmdutil.logmessage(opts) or (_('Automated merge with %s') % url.removeauth(other.url()))) - force_editor = opts.get('force_editor') or opts.get('edit') - n = repo.commit(mod + add + rem, message, - opts['user'], opts['date'], force=True, - force_editor=force_editor) + editor = cmdutil.commiteditor + if opts.get('force_editor') or opts.get('edit'): + editor = cmdutil.commitforceeditor + n = repo.commit(mod + add + rem, message, opts['user'], + opts['date'], force=True, editor=editor) ui.status(_('new changeset %d:%s merges remote changes ' 'with local\n') % (repo.changelog.rev(n), short(n)))