equal
deleted
inserted
replaced
221 The bundle is a returned as a single in-memory binary blob. |
221 The bundle is a returned as a single in-memory binary blob. |
222 """ |
222 """ |
223 ui = repo.ui |
223 ui = repo.ui |
224 tmpdir = tempfile.mkdtemp(prefix='hg-email-bundle-') |
224 tmpdir = tempfile.mkdtemp(prefix='hg-email-bundle-') |
225 tmpfn = os.path.join(tmpdir, 'bundle') |
225 tmpfn = os.path.join(tmpdir, 'bundle') |
|
226 btype = ui.config('patchbomb', 'bundletype') |
|
227 if btype: |
|
228 opts['type'] = btype |
226 try: |
229 try: |
227 commands.bundle(ui, repo, tmpfn, dest, **opts) |
230 commands.bundle(ui, repo, tmpfn, dest, **opts) |
228 fp = open(tmpfn, 'rb') |
231 fp = open(tmpfn, 'rb') |
229 data = fp.read() |
232 data = fp.read() |
230 fp.close() |
233 fp.close() |
432 in the destination repository (or only those which are ancestors |
435 in the destination repository (or only those which are ancestors |
433 of the specified revisions if any are provided) |
436 of the specified revisions if any are provided) |
434 |
437 |
435 With -b/--bundle, changesets are selected as for --outgoing, but a |
438 With -b/--bundle, changesets are selected as for --outgoing, but a |
436 single email containing a binary Mercurial bundle as an attachment |
439 single email containing a binary Mercurial bundle as an attachment |
437 will be sent. |
440 will be sent. Use the ``patchbomb.bundletype`` config option to |
|
441 control the bundle type as with :hg:`bundle --type`. |
438 |
442 |
439 With -m/--mbox, instead of previewing each patchbomb message in a |
443 With -m/--mbox, instead of previewing each patchbomb message in a |
440 pager or sending the messages directly, it will create a UNIX |
444 pager or sending the messages directly, it will create a UNIX |
441 mailbox file with the patch emails. This mailbox file can be |
445 mailbox file with the patch emails. This mailbox file can be |
442 previewed with any mail user agent which supports UNIX mbox |
446 previewed with any mail user agent which supports UNIX mbox |