##// END OF EJS Templates
patchbomb: respect the `--git` option...
Matt Harbison -
r51141:a6b49787 stable
parent child Browse files
Show More
@@ -1,1002 +1,1007 b''
1 # patchbomb.py - sending Mercurial changesets as patch emails
1 # patchbomb.py - sending Mercurial changesets as patch emails
2 #
2 #
3 # Copyright 2005-2009 Olivia Mackall <olivia@selenic.com> and others
3 # Copyright 2005-2009 Olivia Mackall <olivia@selenic.com> and others
4 #
4 #
5 # This software may be used and distributed according to the terms of the
5 # This software may be used and distributed according to the terms of the
6 # GNU General Public License version 2 or any later version.
6 # GNU General Public License version 2 or any later version.
7
7
8 '''command to send changesets as (a series of) patch emails
8 '''command to send changesets as (a series of) patch emails
9
9
10 The series is started off with a "[PATCH 0 of N]" introduction, which
10 The series is started off with a "[PATCH 0 of N]" introduction, which
11 describes the series as a whole.
11 describes the series as a whole.
12
12
13 Each patch email has a Subject line of "[PATCH M of N] ...", using the
13 Each patch email has a Subject line of "[PATCH M of N] ...", using the
14 first line of the changeset description as the subject text. The
14 first line of the changeset description as the subject text. The
15 message contains two or three body parts:
15 message contains two or three body parts:
16
16
17 - The changeset description.
17 - The changeset description.
18 - [Optional] The result of running diffstat on the patch.
18 - [Optional] The result of running diffstat on the patch.
19 - The patch itself, as generated by :hg:`export`.
19 - The patch itself, as generated by :hg:`export`.
20
20
21 Each message refers to the first in the series using the In-Reply-To
21 Each message refers to the first in the series using the In-Reply-To
22 and References headers, so they will show up as a sequence in threaded
22 and References headers, so they will show up as a sequence in threaded
23 mail and news readers, and in mail archives.
23 mail and news readers, and in mail archives.
24
24
25 To configure other defaults, add a section like this to your
25 To configure other defaults, add a section like this to your
26 configuration file::
26 configuration file::
27
27
28 [email]
28 [email]
29 from = My Name <my@email>
29 from = My Name <my@email>
30 to = recipient1, recipient2, ...
30 to = recipient1, recipient2, ...
31 cc = cc1, cc2, ...
31 cc = cc1, cc2, ...
32 bcc = bcc1, bcc2, ...
32 bcc = bcc1, bcc2, ...
33 reply-to = address1, address2, ...
33 reply-to = address1, address2, ...
34
34
35 Use ``[patchbomb]`` as configuration section name if you need to
35 Use ``[patchbomb]`` as configuration section name if you need to
36 override global ``[email]`` address settings.
36 override global ``[email]`` address settings.
37
37
38 Then you can use the :hg:`email` command to mail a series of
38 Then you can use the :hg:`email` command to mail a series of
39 changesets as a patchbomb.
39 changesets as a patchbomb.
40
40
41 You can also either configure the method option in the email section
41 You can also either configure the method option in the email section
42 to be a sendmail compatible mailer or fill out the [smtp] section so
42 to be a sendmail compatible mailer or fill out the [smtp] section so
43 that the patchbomb extension can automatically send patchbombs
43 that the patchbomb extension can automatically send patchbombs
44 directly from the commandline. See the [email] and [smtp] sections in
44 directly from the commandline. See the [email] and [smtp] sections in
45 hgrc(5) for details.
45 hgrc(5) for details.
46
46
47 By default, :hg:`email` will prompt for a ``To`` or ``CC`` header if
47 By default, :hg:`email` will prompt for a ``To`` or ``CC`` header if
48 you do not supply one via configuration or the command line. You can
48 you do not supply one via configuration or the command line. You can
49 override this to never prompt by configuring an empty value::
49 override this to never prompt by configuring an empty value::
50
50
51 [email]
51 [email]
52 cc =
52 cc =
53
53
54 You can control the default inclusion of an introduction message with the
54 You can control the default inclusion of an introduction message with the
55 ``patchbomb.intro`` configuration option. The configuration is always
55 ``patchbomb.intro`` configuration option. The configuration is always
56 overwritten by command line flags like --intro and --desc::
56 overwritten by command line flags like --intro and --desc::
57
57
58 [patchbomb]
58 [patchbomb]
59 intro=auto # include introduction message if more than 1 patch (default)
59 intro=auto # include introduction message if more than 1 patch (default)
60 intro=never # never include an introduction message
60 intro=never # never include an introduction message
61 intro=always # always include an introduction message
61 intro=always # always include an introduction message
62
62
63 You can specify a template for flags to be added in subject prefixes. Flags
63 You can specify a template for flags to be added in subject prefixes. Flags
64 specified by --flag option are exported as ``{flags}`` keyword::
64 specified by --flag option are exported as ``{flags}`` keyword::
65
65
66 [patchbomb]
66 [patchbomb]
67 flagtemplate = "{separate(' ',
67 flagtemplate = "{separate(' ',
68 ifeq(branch, 'default', '', branch|upper),
68 ifeq(branch, 'default', '', branch|upper),
69 flags)}"
69 flags)}"
70
70
71 You can set patchbomb to always ask for confirmation by setting
71 You can set patchbomb to always ask for confirmation by setting
72 ``patchbomb.confirm`` to true.
72 ``patchbomb.confirm`` to true.
73 '''
73 '''
74
74
75 import email.encoders as emailencoders
75 import email.encoders as emailencoders
76 import email.mime.base as emimebase
76 import email.mime.base as emimebase
77 import email.mime.multipart as emimemultipart
77 import email.mime.multipart as emimemultipart
78 import email.utils as eutil
78 import email.utils as eutil
79 import os
79 import os
80 import socket
80 import socket
81
81
82 from mercurial.i18n import _
82 from mercurial.i18n import _
83 from mercurial.pycompat import open
83 from mercurial.pycompat import open
84 from mercurial.node import bin
84 from mercurial.node import bin
85 from mercurial import (
85 from mercurial import (
86 cmdutil,
86 cmdutil,
87 commands,
87 commands,
88 encoding,
88 encoding,
89 error,
89 error,
90 formatter,
90 formatter,
91 hg,
91 hg,
92 logcmdutil,
92 logcmdutil,
93 mail,
93 mail,
94 patch,
94 patch,
95 pycompat,
95 pycompat,
96 registrar,
96 registrar,
97 scmutil,
97 scmutil,
98 templater,
98 templater,
99 util,
99 util,
100 )
100 )
101 from mercurial.utils import (
101 from mercurial.utils import (
102 dateutil,
102 dateutil,
103 urlutil,
103 urlutil,
104 )
104 )
105
105
106 stringio = util.stringio
106 stringio = util.stringio
107
107
108 cmdtable = {}
108 cmdtable = {}
109 command = registrar.command(cmdtable)
109 command = registrar.command(cmdtable)
110
110
111 configtable = {}
111 configtable = {}
112 configitem = registrar.configitem(configtable)
112 configitem = registrar.configitem(configtable)
113
113
114 configitem(
114 configitem(
115 b'patchbomb',
115 b'patchbomb',
116 b'bundletype',
116 b'bundletype',
117 default=None,
117 default=None,
118 )
118 )
119 configitem(
119 configitem(
120 b'patchbomb',
120 b'patchbomb',
121 b'bcc',
121 b'bcc',
122 default=None,
122 default=None,
123 )
123 )
124 configitem(
124 configitem(
125 b'patchbomb',
125 b'patchbomb',
126 b'cc',
126 b'cc',
127 default=None,
127 default=None,
128 )
128 )
129 configitem(
129 configitem(
130 b'patchbomb',
130 b'patchbomb',
131 b'confirm',
131 b'confirm',
132 default=False,
132 default=False,
133 )
133 )
134 configitem(
134 configitem(
135 b'patchbomb',
135 b'patchbomb',
136 b'flagtemplate',
136 b'flagtemplate',
137 default=None,
137 default=None,
138 )
138 )
139 configitem(
139 configitem(
140 b'patchbomb',
140 b'patchbomb',
141 b'from',
141 b'from',
142 default=None,
142 default=None,
143 )
143 )
144 configitem(
144 configitem(
145 b'patchbomb',
145 b'patchbomb',
146 b'intro',
146 b'intro',
147 default=b'auto',
147 default=b'auto',
148 )
148 )
149 configitem(
149 configitem(
150 b'patchbomb',
150 b'patchbomb',
151 b'publicurl',
151 b'publicurl',
152 default=None,
152 default=None,
153 )
153 )
154 configitem(
154 configitem(
155 b'patchbomb',
155 b'patchbomb',
156 b'reply-to',
156 b'reply-to',
157 default=None,
157 default=None,
158 )
158 )
159 configitem(
159 configitem(
160 b'patchbomb',
160 b'patchbomb',
161 b'to',
161 b'to',
162 default=None,
162 default=None,
163 )
163 )
164
164
165 # Note for extension authors: ONLY specify testedwith = 'ships-with-hg-core' for
165 # Note for extension authors: ONLY specify testedwith = 'ships-with-hg-core' for
166 # extensions which SHIP WITH MERCURIAL. Non-mainline extensions should
166 # extensions which SHIP WITH MERCURIAL. Non-mainline extensions should
167 # be specifying the version(s) of Mercurial they are tested with, or
167 # be specifying the version(s) of Mercurial they are tested with, or
168 # leave the attribute unspecified.
168 # leave the attribute unspecified.
169 testedwith = b'ships-with-hg-core'
169 testedwith = b'ships-with-hg-core'
170
170
171
171
172 def _addpullheader(seq, ctx):
172 def _addpullheader(seq, ctx):
173 """Add a header pointing to a public URL where the changeset is available"""
173 """Add a header pointing to a public URL where the changeset is available"""
174 repo = ctx.repo()
174 repo = ctx.repo()
175 # experimental config: patchbomb.publicurl
175 # experimental config: patchbomb.publicurl
176 # waiting for some logic that check that the changeset are available on the
176 # waiting for some logic that check that the changeset are available on the
177 # destination before patchbombing anything.
177 # destination before patchbombing anything.
178 publicurl = repo.ui.config(b'patchbomb', b'publicurl')
178 publicurl = repo.ui.config(b'patchbomb', b'publicurl')
179 if publicurl:
179 if publicurl:
180 return b'Available At %s\n# hg pull %s -r %s' % (
180 return b'Available At %s\n# hg pull %s -r %s' % (
181 publicurl,
181 publicurl,
182 publicurl,
182 publicurl,
183 ctx,
183 ctx,
184 )
184 )
185 return None
185 return None
186
186
187
187
188 def uisetup(ui):
188 def uisetup(ui):
189 cmdutil.extraexport.append(b'pullurl')
189 cmdutil.extraexport.append(b'pullurl')
190 cmdutil.extraexportmap[b'pullurl'] = _addpullheader
190 cmdutil.extraexportmap[b'pullurl'] = _addpullheader
191
191
192
192
193 def reposetup(ui, repo):
193 def reposetup(ui, repo):
194 if not repo.local():
194 if not repo.local():
195 return
195 return
196 repo._wlockfreeprefix.add(b'last-email.txt')
196 repo._wlockfreeprefix.add(b'last-email.txt')
197
197
198
198
199 def prompt(ui, prompt, default=None, rest=b':'):
199 def prompt(ui, prompt, default=None, rest=b':'):
200 if default:
200 if default:
201 prompt += b' [%s]' % default
201 prompt += b' [%s]' % default
202 return ui.prompt(prompt + rest, default)
202 return ui.prompt(prompt + rest, default)
203
203
204
204
205 def introwanted(ui, opts, number):
205 def introwanted(ui, opts, number):
206 '''is an introductory message apparently wanted?'''
206 '''is an introductory message apparently wanted?'''
207 introconfig = ui.config(b'patchbomb', b'intro')
207 introconfig = ui.config(b'patchbomb', b'intro')
208 if opts.get(b'intro') or opts.get(b'desc'):
208 if opts.get(b'intro') or opts.get(b'desc'):
209 intro = True
209 intro = True
210 elif introconfig == b'always':
210 elif introconfig == b'always':
211 intro = True
211 intro = True
212 elif introconfig == b'never':
212 elif introconfig == b'never':
213 intro = False
213 intro = False
214 elif introconfig == b'auto':
214 elif introconfig == b'auto':
215 intro = number > 1
215 intro = number > 1
216 else:
216 else:
217 ui.write_err(
217 ui.write_err(
218 _(b'warning: invalid patchbomb.intro value "%s"\n') % introconfig
218 _(b'warning: invalid patchbomb.intro value "%s"\n') % introconfig
219 )
219 )
220 ui.write_err(_(b'(should be one of always, never, auto)\n'))
220 ui.write_err(_(b'(should be one of always, never, auto)\n'))
221 intro = number > 1
221 intro = number > 1
222 return intro
222 return intro
223
223
224
224
225 def _formatflags(ui, repo, rev, flags):
225 def _formatflags(ui, repo, rev, flags):
226 """build flag string optionally by template"""
226 """build flag string optionally by template"""
227 tmpl = ui.config(b'patchbomb', b'flagtemplate')
227 tmpl = ui.config(b'patchbomb', b'flagtemplate')
228 if not tmpl:
228 if not tmpl:
229 return b' '.join(flags)
229 return b' '.join(flags)
230 out = util.stringio()
230 out = util.stringio()
231 spec = formatter.literal_templatespec(templater.unquotestring(tmpl))
231 spec = formatter.literal_templatespec(templater.unquotestring(tmpl))
232 with formatter.templateformatter(ui, out, b'patchbombflag', {}, spec) as fm:
232 with formatter.templateformatter(ui, out, b'patchbombflag', {}, spec) as fm:
233 fm.startitem()
233 fm.startitem()
234 fm.context(ctx=repo[rev])
234 fm.context(ctx=repo[rev])
235 fm.write(b'flags', b'%s', fm.formatlist(flags, name=b'flag'))
235 fm.write(b'flags', b'%s', fm.formatlist(flags, name=b'flag'))
236 return out.getvalue()
236 return out.getvalue()
237
237
238
238
239 def _formatprefix(ui, repo, rev, flags, idx, total, numbered):
239 def _formatprefix(ui, repo, rev, flags, idx, total, numbered):
240 """build prefix to patch subject"""
240 """build prefix to patch subject"""
241 flag = _formatflags(ui, repo, rev, flags)
241 flag = _formatflags(ui, repo, rev, flags)
242 if flag:
242 if flag:
243 flag = b' ' + flag
243 flag = b' ' + flag
244
244
245 if not numbered:
245 if not numbered:
246 return b'[PATCH%s]' % flag
246 return b'[PATCH%s]' % flag
247 else:
247 else:
248 tlen = len(b"%d" % total)
248 tlen = len(b"%d" % total)
249 return b'[PATCH %0*d of %d%s]' % (tlen, idx, total, flag)
249 return b'[PATCH %0*d of %d%s]' % (tlen, idx, total, flag)
250
250
251
251
252 def makepatch(
252 def makepatch(
253 ui,
253 ui,
254 repo,
254 repo,
255 rev,
255 rev,
256 patchlines,
256 patchlines,
257 opts,
257 opts,
258 _charsets,
258 _charsets,
259 idx,
259 idx,
260 total,
260 total,
261 numbered,
261 numbered,
262 patchname=None,
262 patchname=None,
263 ):
263 ):
264
264
265 desc = []
265 desc = []
266 node = None
266 node = None
267 body = b''
267 body = b''
268
268
269 for line in patchlines:
269 for line in patchlines:
270 if line.startswith(b'#'):
270 if line.startswith(b'#'):
271 if line.startswith(b'# Node ID'):
271 if line.startswith(b'# Node ID'):
272 node = line.split()[-1]
272 node = line.split()[-1]
273 continue
273 continue
274 if line.startswith(b'diff -r') or line.startswith(b'diff --git'):
274 if line.startswith(b'diff -r') or line.startswith(b'diff --git'):
275 break
275 break
276 desc.append(line)
276 desc.append(line)
277
277
278 if not patchname and not node:
278 if not patchname and not node:
279 raise ValueError
279 raise ValueError
280
280
281 if opts.get(b'attach') and not opts.get(b'body'):
281 if opts.get(b'attach') and not opts.get(b'body'):
282 body = (
282 body = (
283 b'\n'.join(desc[1:]).strip()
283 b'\n'.join(desc[1:]).strip()
284 or b'Patch subject is complete summary.'
284 or b'Patch subject is complete summary.'
285 )
285 )
286 body += b'\n\n\n'
286 body += b'\n\n\n'
287
287
288 if opts.get(b'plain'):
288 if opts.get(b'plain'):
289 while patchlines and patchlines[0].startswith(b'# '):
289 while patchlines and patchlines[0].startswith(b'# '):
290 patchlines.pop(0)
290 patchlines.pop(0)
291 if patchlines:
291 if patchlines:
292 patchlines.pop(0)
292 patchlines.pop(0)
293 while patchlines and not patchlines[0].strip():
293 while patchlines and not patchlines[0].strip():
294 patchlines.pop(0)
294 patchlines.pop(0)
295
295
296 ds = patch.diffstat(patchlines)
296 ds = patch.diffstat(patchlines)
297 if opts.get(b'diffstat'):
297 if opts.get(b'diffstat'):
298 body += ds + b'\n\n'
298 body += ds + b'\n\n'
299
299
300 addattachment = opts.get(b'attach') or opts.get(b'inline')
300 addattachment = opts.get(b'attach') or opts.get(b'inline')
301 if not addattachment or opts.get(b'body'):
301 if not addattachment or opts.get(b'body'):
302 body += b'\n'.join(patchlines)
302 body += b'\n'.join(patchlines)
303
303
304 if addattachment:
304 if addattachment:
305 msg = emimemultipart.MIMEMultipart()
305 msg = emimemultipart.MIMEMultipart()
306 if body:
306 if body:
307 msg.attach(mail.mimeencode(ui, body, _charsets, opts.get(b'test')))
307 msg.attach(mail.mimeencode(ui, body, _charsets, opts.get(b'test')))
308 p = mail.mimetextpatch(
308 p = mail.mimetextpatch(
309 b'\n'.join(patchlines), 'x-patch', opts.get(b'test')
309 b'\n'.join(patchlines), 'x-patch', opts.get(b'test')
310 )
310 )
311 binnode = bin(node)
311 binnode = bin(node)
312 # if node is mq patch, it will have the patch file's name as a tag
312 # if node is mq patch, it will have the patch file's name as a tag
313 if not patchname:
313 if not patchname:
314 patchtags = [
314 patchtags = [
315 t
315 t
316 for t in repo.nodetags(binnode)
316 for t in repo.nodetags(binnode)
317 if t.endswith(b'.patch') or t.endswith(b'.diff')
317 if t.endswith(b'.patch') or t.endswith(b'.diff')
318 ]
318 ]
319 if patchtags:
319 if patchtags:
320 patchname = patchtags[0]
320 patchname = patchtags[0]
321 elif total > 1:
321 elif total > 1:
322 patchname = cmdutil.makefilename(
322 patchname = cmdutil.makefilename(
323 repo[node], b'%b-%n.patch', seqno=idx, total=total
323 repo[node], b'%b-%n.patch', seqno=idx, total=total
324 )
324 )
325 else:
325 else:
326 patchname = cmdutil.makefilename(repo[node], b'%b.patch')
326 patchname = cmdutil.makefilename(repo[node], b'%b.patch')
327 disposition = r'inline'
327 disposition = r'inline'
328 if opts.get(b'attach'):
328 if opts.get(b'attach'):
329 disposition = r'attachment'
329 disposition = r'attachment'
330 p['Content-Disposition'] = (
330 p['Content-Disposition'] = (
331 disposition + '; filename=' + encoding.strfromlocal(patchname)
331 disposition + '; filename=' + encoding.strfromlocal(patchname)
332 )
332 )
333 msg.attach(p)
333 msg.attach(p)
334 else:
334 else:
335 msg = mail.mimetextpatch(body, display=opts.get(b'test'))
335 msg = mail.mimetextpatch(body, display=opts.get(b'test'))
336
336
337 prefix = _formatprefix(
337 prefix = _formatprefix(
338 ui, repo, rev, opts.get(b'flag'), idx, total, numbered
338 ui, repo, rev, opts.get(b'flag'), idx, total, numbered
339 )
339 )
340 subj = desc[0].strip().rstrip(b'. ')
340 subj = desc[0].strip().rstrip(b'. ')
341 if not numbered:
341 if not numbered:
342 subj = b' '.join([prefix, opts.get(b'subject') or subj])
342 subj = b' '.join([prefix, opts.get(b'subject') or subj])
343 else:
343 else:
344 subj = b' '.join([prefix, subj])
344 subj = b' '.join([prefix, subj])
345 msg['Subject'] = mail.headencode(ui, subj, _charsets, opts.get(b'test'))
345 msg['Subject'] = mail.headencode(ui, subj, _charsets, opts.get(b'test'))
346 msg['X-Mercurial-Node'] = pycompat.sysstr(node)
346 msg['X-Mercurial-Node'] = pycompat.sysstr(node)
347 msg['X-Mercurial-Series-Index'] = '%i' % idx
347 msg['X-Mercurial-Series-Index'] = '%i' % idx
348 msg['X-Mercurial-Series-Total'] = '%i' % total
348 msg['X-Mercurial-Series-Total'] = '%i' % total
349 return msg, subj, ds
349 return msg, subj, ds
350
350
351
351
352 def _getpatches(repo, revs, **opts):
352 def _getpatches(repo, revs, **opts):
353 """return a list of patches for a list of revisions
353 """return a list of patches for a list of revisions
354
354
355 Each patch in the list is itself a list of lines.
355 Each patch in the list is itself a list of lines.
356 """
356 """
357 ui = repo.ui
357 ui = repo.ui
358 prev = repo[b'.'].rev()
358 prev = repo[b'.'].rev()
359 for r in revs:
359 for r in revs:
360 if r == prev and (repo[None].files() or repo[None].deleted()):
360 if r == prev and (repo[None].files() or repo[None].deleted()):
361 ui.warn(_(b'warning: working directory has uncommitted changes\n'))
361 ui.warn(_(b'warning: working directory has uncommitted changes\n'))
362 output = stringio()
362 output = stringio()
363 cmdutil.exportfile(
363 cmdutil.exportfile(
364 repo, [r], output, opts=patch.difffeatureopts(ui, opts, git=True)
364 repo,
365 [r],
366 output,
367 opts=patch.difffeatureopts(
368 ui, pycompat.byteskwargs(opts), git=True
369 ),
365 )
370 )
366 yield output.getvalue().split(b'\n')
371 yield output.getvalue().split(b'\n')
367
372
368
373
369 def _getbundle(repo, dest, **opts):
374 def _getbundle(repo, dest, **opts):
370 """return a bundle containing changesets missing in "dest"
375 """return a bundle containing changesets missing in "dest"
371
376
372 The `opts` keyword-arguments are the same as the one accepted by the
377 The `opts` keyword-arguments are the same as the one accepted by the
373 `bundle` command.
378 `bundle` command.
374
379
375 The bundle is a returned as a single in-memory binary blob.
380 The bundle is a returned as a single in-memory binary blob.
376 """
381 """
377 ui = repo.ui
382 ui = repo.ui
378 tmpdir = pycompat.mkdtemp(prefix=b'hg-email-bundle-')
383 tmpdir = pycompat.mkdtemp(prefix=b'hg-email-bundle-')
379 tmpfn = os.path.join(tmpdir, b'bundle')
384 tmpfn = os.path.join(tmpdir, b'bundle')
380 btype = ui.config(b'patchbomb', b'bundletype')
385 btype = ui.config(b'patchbomb', b'bundletype')
381 if btype:
386 if btype:
382 opts['type'] = btype
387 opts['type'] = btype
383 try:
388 try:
384 dests = []
389 dests = []
385 if dest:
390 if dest:
386 dests = [dest]
391 dests = [dest]
387 commands.bundle(ui, repo, tmpfn, *dests, **opts)
392 commands.bundle(ui, repo, tmpfn, *dests, **opts)
388 return util.readfile(tmpfn)
393 return util.readfile(tmpfn)
389 finally:
394 finally:
390 try:
395 try:
391 os.unlink(tmpfn)
396 os.unlink(tmpfn)
392 except OSError:
397 except OSError:
393 pass
398 pass
394 os.rmdir(tmpdir)
399 os.rmdir(tmpdir)
395
400
396
401
397 def _getdescription(repo, defaultbody, sender, **opts):
402 def _getdescription(repo, defaultbody, sender, **opts):
398 """obtain the body of the introduction message and return it
403 """obtain the body of the introduction message and return it
399
404
400 This is also used for the body of email with an attached bundle.
405 This is also used for the body of email with an attached bundle.
401
406
402 The body can be obtained either from the command line option or entered by
407 The body can be obtained either from the command line option or entered by
403 the user through the editor.
408 the user through the editor.
404 """
409 """
405 ui = repo.ui
410 ui = repo.ui
406 if opts.get('desc'):
411 if opts.get('desc'):
407 body = open(opts.get('desc')).read()
412 body = open(opts.get('desc')).read()
408 else:
413 else:
409 ui.write(
414 ui.write(
410 _(b'\nWrite the introductory message for the patch series.\n\n')
415 _(b'\nWrite the introductory message for the patch series.\n\n')
411 )
416 )
412 body = ui.edit(
417 body = ui.edit(
413 defaultbody, sender, repopath=repo.path, action=b'patchbombbody'
418 defaultbody, sender, repopath=repo.path, action=b'patchbombbody'
414 )
419 )
415 # Save series description in case sendmail fails
420 # Save series description in case sendmail fails
416 msgfile = repo.vfs(b'last-email.txt', b'wb')
421 msgfile = repo.vfs(b'last-email.txt', b'wb')
417 msgfile.write(body)
422 msgfile.write(body)
418 msgfile.close()
423 msgfile.close()
419 return body
424 return body
420
425
421
426
422 def _getbundlemsgs(repo, sender, bundle, **opts):
427 def _getbundlemsgs(repo, sender, bundle, **opts):
423 """Get the full email for sending a given bundle
428 """Get the full email for sending a given bundle
424
429
425 This function returns a list of "email" tuples (subject, content, None).
430 This function returns a list of "email" tuples (subject, content, None).
426 The list is always one message long in that case.
431 The list is always one message long in that case.
427 """
432 """
428 ui = repo.ui
433 ui = repo.ui
429 _charsets = mail._charsets(ui)
434 _charsets = mail._charsets(ui)
430 subj = opts.get('subject') or prompt(
435 subj = opts.get('subject') or prompt(
431 ui, b'Subject:', b'A bundle for your repository'
436 ui, b'Subject:', b'A bundle for your repository'
432 )
437 )
433
438
434 body = _getdescription(repo, b'', sender, **opts)
439 body = _getdescription(repo, b'', sender, **opts)
435 msg = emimemultipart.MIMEMultipart()
440 msg = emimemultipart.MIMEMultipart()
436 if body:
441 if body:
437 msg.attach(mail.mimeencode(ui, body, _charsets, opts.get('test')))
442 msg.attach(mail.mimeencode(ui, body, _charsets, opts.get('test')))
438 datapart = emimebase.MIMEBase('application', 'x-mercurial-bundle')
443 datapart = emimebase.MIMEBase('application', 'x-mercurial-bundle')
439 datapart.set_payload(bundle)
444 datapart.set_payload(bundle)
440 bundlename = b'%s.hg' % opts.get('bundlename', b'bundle')
445 bundlename = b'%s.hg' % opts.get('bundlename', b'bundle')
441 datapart.add_header(
446 datapart.add_header(
442 'Content-Disposition',
447 'Content-Disposition',
443 'attachment',
448 'attachment',
444 filename=encoding.strfromlocal(bundlename),
449 filename=encoding.strfromlocal(bundlename),
445 )
450 )
446 emailencoders.encode_base64(datapart)
451 emailencoders.encode_base64(datapart)
447 msg.attach(datapart)
452 msg.attach(datapart)
448 msg['Subject'] = mail.headencode(ui, subj, _charsets, opts.get('test'))
453 msg['Subject'] = mail.headencode(ui, subj, _charsets, opts.get('test'))
449 return [(msg, subj, None)]
454 return [(msg, subj, None)]
450
455
451
456
452 def _makeintro(repo, sender, revs, patches, **opts):
457 def _makeintro(repo, sender, revs, patches, **opts):
453 """make an introduction email, asking the user for content if needed
458 """make an introduction email, asking the user for content if needed
454
459
455 email is returned as (subject, body, cumulative-diffstat)"""
460 email is returned as (subject, body, cumulative-diffstat)"""
456 ui = repo.ui
461 ui = repo.ui
457 _charsets = mail._charsets(ui)
462 _charsets = mail._charsets(ui)
458
463
459 # use the last revision which is likely to be a bookmarked head
464 # use the last revision which is likely to be a bookmarked head
460 prefix = _formatprefix(
465 prefix = _formatprefix(
461 ui, repo, revs.last(), opts.get('flag'), 0, len(patches), numbered=True
466 ui, repo, revs.last(), opts.get('flag'), 0, len(patches), numbered=True
462 )
467 )
463 subj = opts.get('subject') or prompt(
468 subj = opts.get('subject') or prompt(
464 ui, b'(optional) Subject: ', rest=prefix, default=b''
469 ui, b'(optional) Subject: ', rest=prefix, default=b''
465 )
470 )
466 if not subj:
471 if not subj:
467 return None # skip intro if the user doesn't bother
472 return None # skip intro if the user doesn't bother
468
473
469 subj = prefix + b' ' + subj
474 subj = prefix + b' ' + subj
470
475
471 body = b''
476 body = b''
472 if opts.get('diffstat'):
477 if opts.get('diffstat'):
473 # generate a cumulative diffstat of the whole patch series
478 # generate a cumulative diffstat of the whole patch series
474 diffstat = patch.diffstat(sum(patches, []))
479 diffstat = patch.diffstat(sum(patches, []))
475 body = b'\n' + diffstat
480 body = b'\n' + diffstat
476 else:
481 else:
477 diffstat = None
482 diffstat = None
478
483
479 body = _getdescription(repo, body, sender, **opts)
484 body = _getdescription(repo, body, sender, **opts)
480 msg = mail.mimeencode(ui, body, _charsets, opts.get('test'))
485 msg = mail.mimeencode(ui, body, _charsets, opts.get('test'))
481 msg['Subject'] = mail.headencode(ui, subj, _charsets, opts.get('test'))
486 msg['Subject'] = mail.headencode(ui, subj, _charsets, opts.get('test'))
482 return (msg, subj, diffstat)
487 return (msg, subj, diffstat)
483
488
484
489
485 def _getpatchmsgs(repo, sender, revs, patchnames=None, **opts):
490 def _getpatchmsgs(repo, sender, revs, patchnames=None, **opts):
486 """return a list of emails from a list of patches
491 """return a list of emails from a list of patches
487
492
488 This involves introduction message creation if necessary.
493 This involves introduction message creation if necessary.
489
494
490 This function returns a list of "email" tuples (subject, content, None).
495 This function returns a list of "email" tuples (subject, content, None).
491 """
496 """
492 bytesopts = pycompat.byteskwargs(opts)
497 bytesopts = pycompat.byteskwargs(opts)
493 ui = repo.ui
498 ui = repo.ui
494 _charsets = mail._charsets(ui)
499 _charsets = mail._charsets(ui)
495 patches = list(_getpatches(repo, revs, **opts))
500 patches = list(_getpatches(repo, revs, **opts))
496 msgs = []
501 msgs = []
497
502
498 ui.write(_(b'this patch series consists of %d patches.\n\n') % len(patches))
503 ui.write(_(b'this patch series consists of %d patches.\n\n') % len(patches))
499
504
500 # build the intro message, or skip it if the user declines
505 # build the intro message, or skip it if the user declines
501 if introwanted(ui, bytesopts, len(patches)):
506 if introwanted(ui, bytesopts, len(patches)):
502 msg = _makeintro(repo, sender, revs, patches, **opts)
507 msg = _makeintro(repo, sender, revs, patches, **opts)
503 if msg:
508 if msg:
504 msgs.append(msg)
509 msgs.append(msg)
505
510
506 # are we going to send more than one message?
511 # are we going to send more than one message?
507 numbered = len(msgs) + len(patches) > 1
512 numbered = len(msgs) + len(patches) > 1
508
513
509 # now generate the actual patch messages
514 # now generate the actual patch messages
510 name = None
515 name = None
511 assert len(revs) == len(patches)
516 assert len(revs) == len(patches)
512 for i, (r, p) in enumerate(zip(revs, patches)):
517 for i, (r, p) in enumerate(zip(revs, patches)):
513 if patchnames:
518 if patchnames:
514 name = patchnames[i]
519 name = patchnames[i]
515 msg = makepatch(
520 msg = makepatch(
516 ui,
521 ui,
517 repo,
522 repo,
518 r,
523 r,
519 p,
524 p,
520 bytesopts,
525 bytesopts,
521 _charsets,
526 _charsets,
522 i + 1,
527 i + 1,
523 len(patches),
528 len(patches),
524 numbered,
529 numbered,
525 name,
530 name,
526 )
531 )
527 msgs.append(msg)
532 msgs.append(msg)
528
533
529 return msgs
534 return msgs
530
535
531
536
532 def _getoutgoing(repo, dest, revs):
537 def _getoutgoing(repo, dest, revs):
533 '''Return the revisions present locally but not in dest'''
538 '''Return the revisions present locally but not in dest'''
534 ui = repo.ui
539 ui = repo.ui
535 paths = urlutil.get_push_paths(repo, ui, [dest] if dest else None)
540 paths = urlutil.get_push_paths(repo, ui, [dest] if dest else None)
536 safe_paths = [urlutil.hidepassword(p.rawloc) for p in paths]
541 safe_paths = [urlutil.hidepassword(p.rawloc) for p in paths]
537 ui.status(_(b'comparing with %s\n') % b','.join(safe_paths))
542 ui.status(_(b'comparing with %s\n') % b','.join(safe_paths))
538
543
539 revs = [r for r in revs if r >= 0]
544 revs = [r for r in revs if r >= 0]
540 if not revs:
545 if not revs:
541 revs = [repo.changelog.tiprev()]
546 revs = [repo.changelog.tiprev()]
542 revs = repo.revs(b'outgoing(%s) and ::%ld', dest or b'', revs)
547 revs = repo.revs(b'outgoing(%s) and ::%ld', dest or b'', revs)
543 if not revs:
548 if not revs:
544 ui.status(_(b"no changes found\n"))
549 ui.status(_(b"no changes found\n"))
545 return revs
550 return revs
546
551
547
552
548 def _msgid(node, timestamp):
553 def _msgid(node, timestamp):
549 try:
554 try:
550 hostname = encoding.strfromlocal(encoding.environ[b'HGHOSTNAME'])
555 hostname = encoding.strfromlocal(encoding.environ[b'HGHOSTNAME'])
551 except KeyError:
556 except KeyError:
552 hostname = socket.getfqdn()
557 hostname = socket.getfqdn()
553 return '<%s.%d@%s>' % (node, timestamp, hostname)
558 return '<%s.%d@%s>' % (node, timestamp, hostname)
554
559
555
560
556 emailopts = [
561 emailopts = [
557 (b'', b'body', None, _(b'send patches as inline message text (default)')),
562 (b'', b'body', None, _(b'send patches as inline message text (default)')),
558 (b'a', b'attach', None, _(b'send patches as attachments')),
563 (b'a', b'attach', None, _(b'send patches as attachments')),
559 (b'i', b'inline', None, _(b'send patches as inline attachments')),
564 (b'i', b'inline', None, _(b'send patches as inline attachments')),
560 (
565 (
561 b'',
566 b'',
562 b'bcc',
567 b'bcc',
563 [],
568 [],
564 _(b'email addresses of blind carbon copy recipients'),
569 _(b'email addresses of blind carbon copy recipients'),
565 _(b'EMAIL'),
570 _(b'EMAIL'),
566 ),
571 ),
567 (b'c', b'cc', [], _(b'email addresses of copy recipients'), _(b'EMAIL')),
572 (b'c', b'cc', [], _(b'email addresses of copy recipients'), _(b'EMAIL')),
568 (b'', b'confirm', None, _(b'ask for confirmation before sending')),
573 (b'', b'confirm', None, _(b'ask for confirmation before sending')),
569 (b'd', b'diffstat', None, _(b'add diffstat output to messages')),
574 (b'd', b'diffstat', None, _(b'add diffstat output to messages')),
570 (
575 (
571 b'',
576 b'',
572 b'date',
577 b'date',
573 b'',
578 b'',
574 _(b'use the given date as the sending date'),
579 _(b'use the given date as the sending date'),
575 _(b'DATE'),
580 _(b'DATE'),
576 ),
581 ),
577 (
582 (
578 b'',
583 b'',
579 b'desc',
584 b'desc',
580 b'',
585 b'',
581 _(b'use the given file as the series description'),
586 _(b'use the given file as the series description'),
582 _(b'FILE'),
587 _(b'FILE'),
583 ),
588 ),
584 (b'f', b'from', b'', _(b'email address of sender'), _(b'EMAIL')),
589 (b'f', b'from', b'', _(b'email address of sender'), _(b'EMAIL')),
585 (b'n', b'test', None, _(b'print messages that would be sent')),
590 (b'n', b'test', None, _(b'print messages that would be sent')),
586 (
591 (
587 b'm',
592 b'm',
588 b'mbox',
593 b'mbox',
589 b'',
594 b'',
590 _(b'write messages to mbox file instead of sending them'),
595 _(b'write messages to mbox file instead of sending them'),
591 _(b'FILE'),
596 _(b'FILE'),
592 ),
597 ),
593 (
598 (
594 b'',
599 b'',
595 b'reply-to',
600 b'reply-to',
596 [],
601 [],
597 _(b'email addresses replies should be sent to'),
602 _(b'email addresses replies should be sent to'),
598 _(b'EMAIL'),
603 _(b'EMAIL'),
599 ),
604 ),
600 (
605 (
601 b's',
606 b's',
602 b'subject',
607 b'subject',
603 b'',
608 b'',
604 _(b'subject of first message (intro or single patch)'),
609 _(b'subject of first message (intro or single patch)'),
605 _(b'TEXT'),
610 _(b'TEXT'),
606 ),
611 ),
607 (
612 (
608 b'',
613 b'',
609 b'in-reply-to',
614 b'in-reply-to',
610 b'',
615 b'',
611 _(b'message identifier to reply to'),
616 _(b'message identifier to reply to'),
612 _(b'MSGID'),
617 _(b'MSGID'),
613 ),
618 ),
614 (b'', b'flag', [], _(b'flags to add in subject prefixes'), _(b'FLAG')),
619 (b'', b'flag', [], _(b'flags to add in subject prefixes'), _(b'FLAG')),
615 (b't', b'to', [], _(b'email addresses of recipients'), _(b'EMAIL')),
620 (b't', b'to', [], _(b'email addresses of recipients'), _(b'EMAIL')),
616 ]
621 ]
617
622
618
623
619 @command(
624 @command(
620 b'email',
625 b'email',
621 [
626 [
622 (b'g', b'git', None, _(b'use git extended diff format')),
627 (b'g', b'git', None, _(b'use git extended diff format')),
623 (b'', b'plain', None, _(b'omit hg patch header')),
628 (b'', b'plain', None, _(b'omit hg patch header')),
624 (
629 (
625 b'o',
630 b'o',
626 b'outgoing',
631 b'outgoing',
627 None,
632 None,
628 _(b'send changes not found in the target repository'),
633 _(b'send changes not found in the target repository'),
629 ),
634 ),
630 (
635 (
631 b'b',
636 b'b',
632 b'bundle',
637 b'bundle',
633 None,
638 None,
634 _(b'send changes not in target as a binary bundle'),
639 _(b'send changes not in target as a binary bundle'),
635 ),
640 ),
636 (
641 (
637 b'B',
642 b'B',
638 b'bookmark',
643 b'bookmark',
639 b'',
644 b'',
640 _(b'send changes only reachable by given bookmark'),
645 _(b'send changes only reachable by given bookmark'),
641 _(b'BOOKMARK'),
646 _(b'BOOKMARK'),
642 ),
647 ),
643 (
648 (
644 b'',
649 b'',
645 b'bundlename',
650 b'bundlename',
646 b'bundle',
651 b'bundle',
647 _(b'name of the bundle attachment file'),
652 _(b'name of the bundle attachment file'),
648 _(b'NAME'),
653 _(b'NAME'),
649 ),
654 ),
650 (b'r', b'rev', [], _(b'a revision to send'), _(b'REV')),
655 (b'r', b'rev', [], _(b'a revision to send'), _(b'REV')),
651 (
656 (
652 b'',
657 b'',
653 b'force',
658 b'force',
654 None,
659 None,
655 _(
660 _(
656 b'run even when remote repository is unrelated '
661 b'run even when remote repository is unrelated '
657 b'(with -b/--bundle)'
662 b'(with -b/--bundle)'
658 ),
663 ),
659 ),
664 ),
660 (
665 (
661 b'',
666 b'',
662 b'base',
667 b'base',
663 [],
668 [],
664 _(
669 _(
665 b'a base changeset to specify instead of a destination '
670 b'a base changeset to specify instead of a destination '
666 b'(with -b/--bundle)'
671 b'(with -b/--bundle)'
667 ),
672 ),
668 _(b'REV'),
673 _(b'REV'),
669 ),
674 ),
670 (
675 (
671 b'',
676 b'',
672 b'intro',
677 b'intro',
673 None,
678 None,
674 _(b'send an introduction email for a single patch'),
679 _(b'send an introduction email for a single patch'),
675 ),
680 ),
676 ]
681 ]
677 + emailopts
682 + emailopts
678 + cmdutil.remoteopts,
683 + cmdutil.remoteopts,
679 _(b'hg email [OPTION]... [DEST]...'),
684 _(b'hg email [OPTION]... [DEST]...'),
680 helpcategory=command.CATEGORY_IMPORT_EXPORT,
685 helpcategory=command.CATEGORY_IMPORT_EXPORT,
681 )
686 )
682 def email(ui, repo, *revs, **opts):
687 def email(ui, repo, *revs, **opts):
683 """send changesets by email
688 """send changesets by email
684
689
685 By default, diffs are sent in the format generated by
690 By default, diffs are sent in the format generated by
686 :hg:`export`, one per message. The series starts with a "[PATCH 0
691 :hg:`export`, one per message. The series starts with a "[PATCH 0
687 of N]" introduction, which describes the series as a whole.
692 of N]" introduction, which describes the series as a whole.
688
693
689 Each patch email has a Subject line of "[PATCH M of N] ...", using
694 Each patch email has a Subject line of "[PATCH M of N] ...", using
690 the first line of the changeset description as the subject text.
695 the first line of the changeset description as the subject text.
691 The message contains two or three parts. First, the changeset
696 The message contains two or three parts. First, the changeset
692 description.
697 description.
693
698
694 With the -d/--diffstat option, if the diffstat program is
699 With the -d/--diffstat option, if the diffstat program is
695 installed, the result of running diffstat on the patch is inserted.
700 installed, the result of running diffstat on the patch is inserted.
696
701
697 Finally, the patch itself, as generated by :hg:`export`.
702 Finally, the patch itself, as generated by :hg:`export`.
698
703
699 With the -d/--diffstat or --confirm options, you will be presented
704 With the -d/--diffstat or --confirm options, you will be presented
700 with a final summary of all messages and asked for confirmation before
705 with a final summary of all messages and asked for confirmation before
701 the messages are sent.
706 the messages are sent.
702
707
703 By default the patch is included as text in the email body for
708 By default the patch is included as text in the email body for
704 easy reviewing. Using the -a/--attach option will instead create
709 easy reviewing. Using the -a/--attach option will instead create
705 an attachment for the patch. With -i/--inline an inline attachment
710 an attachment for the patch. With -i/--inline an inline attachment
706 will be created. You can include a patch both as text in the email
711 will be created. You can include a patch both as text in the email
707 body and as a regular or an inline attachment by combining the
712 body and as a regular or an inline attachment by combining the
708 -a/--attach or -i/--inline with the --body option.
713 -a/--attach or -i/--inline with the --body option.
709
714
710 With -B/--bookmark changesets reachable by the given bookmark are
715 With -B/--bookmark changesets reachable by the given bookmark are
711 selected.
716 selected.
712
717
713 With -o/--outgoing, emails will be generated for patches not found
718 With -o/--outgoing, emails will be generated for patches not found
714 in the destination repository (or only those which are ancestors
719 in the destination repository (or only those which are ancestors
715 of the specified revisions if any are provided)
720 of the specified revisions if any are provided)
716
721
717 With -b/--bundle, changesets are selected as for --outgoing, but a
722 With -b/--bundle, changesets are selected as for --outgoing, but a
718 single email containing a binary Mercurial bundle as an attachment
723 single email containing a binary Mercurial bundle as an attachment
719 will be sent. Use the ``patchbomb.bundletype`` config option to
724 will be sent. Use the ``patchbomb.bundletype`` config option to
720 control the bundle type as with :hg:`bundle --type`.
725 control the bundle type as with :hg:`bundle --type`.
721
726
722 With -m/--mbox, instead of previewing each patchbomb message in a
727 With -m/--mbox, instead of previewing each patchbomb message in a
723 pager or sending the messages directly, it will create a UNIX
728 pager or sending the messages directly, it will create a UNIX
724 mailbox file with the patch emails. This mailbox file can be
729 mailbox file with the patch emails. This mailbox file can be
725 previewed with any mail user agent which supports UNIX mbox
730 previewed with any mail user agent which supports UNIX mbox
726 files.
731 files.
727
732
728 With -n/--test, all steps will run, but mail will not be sent.
733 With -n/--test, all steps will run, but mail will not be sent.
729 You will be prompted for an email recipient address, a subject and
734 You will be prompted for an email recipient address, a subject and
730 an introductory message describing the patches of your patchbomb.
735 an introductory message describing the patches of your patchbomb.
731 Then when all is done, patchbomb messages are displayed.
736 Then when all is done, patchbomb messages are displayed.
732
737
733 In case email sending fails, you will find a backup of your series
738 In case email sending fails, you will find a backup of your series
734 introductory message in ``.hg/last-email.txt``.
739 introductory message in ``.hg/last-email.txt``.
735
740
736 The default behavior of this command can be customized through
741 The default behavior of this command can be customized through
737 configuration. (See :hg:`help patchbomb` for details)
742 configuration. (See :hg:`help patchbomb` for details)
738
743
739 Examples::
744 Examples::
740
745
741 hg email -r 3000 # send patch 3000 only
746 hg email -r 3000 # send patch 3000 only
742 hg email -r 3000 -r 3001 # send patches 3000 and 3001
747 hg email -r 3000 -r 3001 # send patches 3000 and 3001
743 hg email -r 3000:3005 # send patches 3000 through 3005
748 hg email -r 3000:3005 # send patches 3000 through 3005
744 hg email 3000 # send patch 3000 (deprecated)
749 hg email 3000 # send patch 3000 (deprecated)
745
750
746 hg email -o # send all patches not in default
751 hg email -o # send all patches not in default
747 hg email -o DEST # send all patches not in DEST
752 hg email -o DEST # send all patches not in DEST
748 hg email -o -r 3000 # send all ancestors of 3000 not in default
753 hg email -o -r 3000 # send all ancestors of 3000 not in default
749 hg email -o -r 3000 DEST # send all ancestors of 3000 not in DEST
754 hg email -o -r 3000 DEST # send all ancestors of 3000 not in DEST
750
755
751 hg email -B feature # send all ancestors of feature bookmark
756 hg email -B feature # send all ancestors of feature bookmark
752
757
753 hg email -b # send bundle of all patches not in default
758 hg email -b # send bundle of all patches not in default
754 hg email -b DEST # send bundle of all patches not in DEST
759 hg email -b DEST # send bundle of all patches not in DEST
755 hg email -b -r 3000 # bundle of all ancestors of 3000 not in default
760 hg email -b -r 3000 # bundle of all ancestors of 3000 not in default
756 hg email -b -r 3000 DEST # bundle of all ancestors of 3000 not in DEST
761 hg email -b -r 3000 DEST # bundle of all ancestors of 3000 not in DEST
757
762
758 hg email -o -m mbox && # generate an mbox file...
763 hg email -o -m mbox && # generate an mbox file...
759 mutt -R -f mbox # ... and view it with mutt
764 mutt -R -f mbox # ... and view it with mutt
760 hg email -o -m mbox && # generate an mbox file ...
765 hg email -o -m mbox && # generate an mbox file ...
761 formail -s sendmail \\ # ... and use formail to send from the mbox
766 formail -s sendmail \\ # ... and use formail to send from the mbox
762 -bm -t < mbox # ... using sendmail
767 -bm -t < mbox # ... using sendmail
763
768
764 Before using this command, you will need to enable email in your
769 Before using this command, you will need to enable email in your
765 hgrc. See the [email] section in hgrc(5) for details.
770 hgrc. See the [email] section in hgrc(5) for details.
766 """
771 """
767 opts = pycompat.byteskwargs(opts)
772 opts = pycompat.byteskwargs(opts)
768
773
769 _charsets = mail._charsets(ui)
774 _charsets = mail._charsets(ui)
770
775
771 bundle = opts.get(b'bundle')
776 bundle = opts.get(b'bundle')
772 date = opts.get(b'date')
777 date = opts.get(b'date')
773 mbox = opts.get(b'mbox')
778 mbox = opts.get(b'mbox')
774 outgoing = opts.get(b'outgoing')
779 outgoing = opts.get(b'outgoing')
775 rev = opts.get(b'rev')
780 rev = opts.get(b'rev')
776 bookmark = opts.get(b'bookmark')
781 bookmark = opts.get(b'bookmark')
777
782
778 if not (opts.get(b'test') or mbox):
783 if not (opts.get(b'test') or mbox):
779 # really sending
784 # really sending
780 mail.validateconfig(ui)
785 mail.validateconfig(ui)
781
786
782 if not (revs or rev or outgoing or bundle or bookmark):
787 if not (revs or rev or outgoing or bundle or bookmark):
783 raise error.Abort(
788 raise error.Abort(
784 _(b'specify at least one changeset with -B, -r or -o')
789 _(b'specify at least one changeset with -B, -r or -o')
785 )
790 )
786
791
787 if outgoing and bundle:
792 if outgoing and bundle:
788 raise error.Abort(
793 raise error.Abort(
789 _(
794 _(
790 b"--outgoing mode always on with --bundle;"
795 b"--outgoing mode always on with --bundle;"
791 b" do not re-specify --outgoing"
796 b" do not re-specify --outgoing"
792 )
797 )
793 )
798 )
794 cmdutil.check_at_most_one_arg(opts, b'rev', b'bookmark')
799 cmdutil.check_at_most_one_arg(opts, b'rev', b'bookmark')
795
800
796 if outgoing or bundle:
801 if outgoing or bundle:
797 if len(revs) > 1:
802 if len(revs) > 1:
798 raise error.Abort(_(b"too many destinations"))
803 raise error.Abort(_(b"too many destinations"))
799 if revs:
804 if revs:
800 dest = revs[0]
805 dest = revs[0]
801 else:
806 else:
802 dest = None
807 dest = None
803 revs = []
808 revs = []
804
809
805 if rev:
810 if rev:
806 if revs:
811 if revs:
807 raise error.Abort(_(b'use only one form to specify the revision'))
812 raise error.Abort(_(b'use only one form to specify the revision'))
808 revs = rev
813 revs = rev
809 elif bookmark:
814 elif bookmark:
810 if bookmark not in repo._bookmarks:
815 if bookmark not in repo._bookmarks:
811 raise error.Abort(_(b"bookmark '%s' not found") % bookmark)
816 raise error.Abort(_(b"bookmark '%s' not found") % bookmark)
812 revs = scmutil.bookmarkrevs(repo, bookmark)
817 revs = scmutil.bookmarkrevs(repo, bookmark)
813
818
814 revs = logcmdutil.revrange(repo, revs)
819 revs = logcmdutil.revrange(repo, revs)
815 if outgoing:
820 if outgoing:
816 revs = _getoutgoing(repo, dest, revs)
821 revs = _getoutgoing(repo, dest, revs)
817 if bundle:
822 if bundle:
818 opts[b'revs'] = [b"%d" % r for r in revs]
823 opts[b'revs'] = [b"%d" % r for r in revs]
819
824
820 # check if revision exist on the public destination
825 # check if revision exist on the public destination
821 publicurl = repo.ui.config(b'patchbomb', b'publicurl')
826 publicurl = repo.ui.config(b'patchbomb', b'publicurl')
822 if publicurl:
827 if publicurl:
823 repo.ui.debug(b'checking that revision exist in the public repo\n')
828 repo.ui.debug(b'checking that revision exist in the public repo\n')
824 try:
829 try:
825 publicpeer = hg.peer(repo, {}, publicurl)
830 publicpeer = hg.peer(repo, {}, publicurl)
826 except error.RepoError:
831 except error.RepoError:
827 repo.ui.write_err(
832 repo.ui.write_err(
828 _(b'unable to access public repo: %s\n') % publicurl
833 _(b'unable to access public repo: %s\n') % publicurl
829 )
834 )
830 raise
835 raise
831 if not publicpeer.capable(b'known'):
836 if not publicpeer.capable(b'known'):
832 repo.ui.debug(b'skipping existence checks: public repo too old\n')
837 repo.ui.debug(b'skipping existence checks: public repo too old\n')
833 else:
838 else:
834 out = [repo[r] for r in revs]
839 out = [repo[r] for r in revs]
835 known = publicpeer.known(h.node() for h in out)
840 known = publicpeer.known(h.node() for h in out)
836 missing = []
841 missing = []
837 for idx, h in enumerate(out):
842 for idx, h in enumerate(out):
838 if not known[idx]:
843 if not known[idx]:
839 missing.append(h)
844 missing.append(h)
840 if missing:
845 if missing:
841 if len(missing) > 1:
846 if len(missing) > 1:
842 msg = _(b'public "%s" is missing %s and %i others')
847 msg = _(b'public "%s" is missing %s and %i others')
843 msg %= (publicurl, missing[0], len(missing) - 1)
848 msg %= (publicurl, missing[0], len(missing) - 1)
844 else:
849 else:
845 msg = _(b'public url %s is missing %s')
850 msg = _(b'public url %s is missing %s')
846 msg %= (publicurl, missing[0])
851 msg %= (publicurl, missing[0])
847 missingrevs = [ctx.rev() for ctx in missing]
852 missingrevs = [ctx.rev() for ctx in missing]
848 revhint = b' '.join(
853 revhint = b' '.join(
849 b'-r %s' % h for h in repo.set(b'heads(%ld)', missingrevs)
854 b'-r %s' % h for h in repo.set(b'heads(%ld)', missingrevs)
850 )
855 )
851 hint = _(b"use 'hg push %s %s'") % (publicurl, revhint)
856 hint = _(b"use 'hg push %s %s'") % (publicurl, revhint)
852 raise error.Abort(msg, hint=hint)
857 raise error.Abort(msg, hint=hint)
853
858
854 # start
859 # start
855 if date:
860 if date:
856 start_time = dateutil.parsedate(date)
861 start_time = dateutil.parsedate(date)
857 else:
862 else:
858 start_time = dateutil.makedate()
863 start_time = dateutil.makedate()
859
864
860 def genmsgid(id):
865 def genmsgid(id):
861 return _msgid(id[:20], int(start_time[0]))
866 return _msgid(id[:20], int(start_time[0]))
862
867
863 # deprecated config: patchbomb.from
868 # deprecated config: patchbomb.from
864 sender = (
869 sender = (
865 opts.get(b'from')
870 opts.get(b'from')
866 or ui.config(b'email', b'from')
871 or ui.config(b'email', b'from')
867 or ui.config(b'patchbomb', b'from')
872 or ui.config(b'patchbomb', b'from')
868 or prompt(ui, b'From', ui.username())
873 or prompt(ui, b'From', ui.username())
869 )
874 )
870
875
871 if bundle:
876 if bundle:
872 stropts = pycompat.strkwargs(opts)
877 stropts = pycompat.strkwargs(opts)
873 bundledata = _getbundle(repo, dest, **stropts)
878 bundledata = _getbundle(repo, dest, **stropts)
874 bundleopts = stropts.copy()
879 bundleopts = stropts.copy()
875 bundleopts.pop('bundle', None) # already processed
880 bundleopts.pop('bundle', None) # already processed
876 msgs = _getbundlemsgs(repo, sender, bundledata, **bundleopts)
881 msgs = _getbundlemsgs(repo, sender, bundledata, **bundleopts)
877 else:
882 else:
878 msgs = _getpatchmsgs(repo, sender, revs, **pycompat.strkwargs(opts))
883 msgs = _getpatchmsgs(repo, sender, revs, **pycompat.strkwargs(opts))
879
884
880 showaddrs = []
885 showaddrs = []
881
886
882 def getaddrs(header, ask=False, default=None):
887 def getaddrs(header, ask=False, default=None):
883 configkey = header.lower()
888 configkey = header.lower()
884 opt = header.replace(b'-', b'_').lower()
889 opt = header.replace(b'-', b'_').lower()
885 addrs = opts.get(opt)
890 addrs = opts.get(opt)
886 if addrs:
891 if addrs:
887 showaddrs.append(b'%s: %s' % (header, b', '.join(addrs)))
892 showaddrs.append(b'%s: %s' % (header, b', '.join(addrs)))
888 return mail.addrlistencode(ui, addrs, _charsets, opts.get(b'test'))
893 return mail.addrlistencode(ui, addrs, _charsets, opts.get(b'test'))
889
894
890 # not on the command line: fallback to config and then maybe ask
895 # not on the command line: fallback to config and then maybe ask
891 addr = ui.config(b'email', configkey) or ui.config(
896 addr = ui.config(b'email', configkey) or ui.config(
892 b'patchbomb', configkey
897 b'patchbomb', configkey
893 )
898 )
894 if not addr:
899 if not addr:
895 specified = ui.hasconfig(b'email', configkey) or ui.hasconfig(
900 specified = ui.hasconfig(b'email', configkey) or ui.hasconfig(
896 b'patchbomb', configkey
901 b'patchbomb', configkey
897 )
902 )
898 if not specified and ask:
903 if not specified and ask:
899 addr = prompt(ui, header, default=default)
904 addr = prompt(ui, header, default=default)
900 if addr:
905 if addr:
901 showaddrs.append(b'%s: %s' % (header, addr))
906 showaddrs.append(b'%s: %s' % (header, addr))
902 return mail.addrlistencode(ui, [addr], _charsets, opts.get(b'test'))
907 return mail.addrlistencode(ui, [addr], _charsets, opts.get(b'test'))
903 elif default:
908 elif default:
904 return mail.addrlistencode(
909 return mail.addrlistencode(
905 ui, [default], _charsets, opts.get(b'test')
910 ui, [default], _charsets, opts.get(b'test')
906 )
911 )
907 return []
912 return []
908
913
909 to = getaddrs(b'To', ask=True)
914 to = getaddrs(b'To', ask=True)
910 if not to:
915 if not to:
911 # we can get here in non-interactive mode
916 # we can get here in non-interactive mode
912 raise error.Abort(_(b'no recipient addresses provided'))
917 raise error.Abort(_(b'no recipient addresses provided'))
913 cc = getaddrs(b'Cc', ask=True, default=b'')
918 cc = getaddrs(b'Cc', ask=True, default=b'')
914 bcc = getaddrs(b'Bcc')
919 bcc = getaddrs(b'Bcc')
915 replyto = getaddrs(b'Reply-To')
920 replyto = getaddrs(b'Reply-To')
916
921
917 confirm = ui.configbool(b'patchbomb', b'confirm')
922 confirm = ui.configbool(b'patchbomb', b'confirm')
918 confirm |= bool(opts.get(b'diffstat') or opts.get(b'confirm'))
923 confirm |= bool(opts.get(b'diffstat') or opts.get(b'confirm'))
919
924
920 if confirm:
925 if confirm:
921 ui.write(_(b'\nFinal summary:\n\n'), label=b'patchbomb.finalsummary')
926 ui.write(_(b'\nFinal summary:\n\n'), label=b'patchbomb.finalsummary')
922 ui.write((b'From: %s\n' % sender), label=b'patchbomb.from')
927 ui.write((b'From: %s\n' % sender), label=b'patchbomb.from')
923 for addr in showaddrs:
928 for addr in showaddrs:
924 ui.write(b'%s\n' % addr, label=b'patchbomb.to')
929 ui.write(b'%s\n' % addr, label=b'patchbomb.to')
925 for m, subj, ds in msgs:
930 for m, subj, ds in msgs:
926 ui.write((b'Subject: %s\n' % subj), label=b'patchbomb.subject')
931 ui.write((b'Subject: %s\n' % subj), label=b'patchbomb.subject')
927 if ds:
932 if ds:
928 ui.write(ds, label=b'patchbomb.diffstats')
933 ui.write(ds, label=b'patchbomb.diffstats')
929 ui.write(b'\n')
934 ui.write(b'\n')
930 if ui.promptchoice(
935 if ui.promptchoice(
931 _(b'are you sure you want to send (yn)?$$ &Yes $$ &No')
936 _(b'are you sure you want to send (yn)?$$ &Yes $$ &No')
932 ):
937 ):
933 raise error.Abort(_(b'patchbomb canceled'))
938 raise error.Abort(_(b'patchbomb canceled'))
934
939
935 ui.write(b'\n')
940 ui.write(b'\n')
936
941
937 parent = opts.get(b'in_reply_to') or None
942 parent = opts.get(b'in_reply_to') or None
938 # angle brackets may be omitted, they're not semantically part of the msg-id
943 # angle brackets may be omitted, they're not semantically part of the msg-id
939 if parent is not None:
944 if parent is not None:
940 parent = encoding.strfromlocal(parent)
945 parent = encoding.strfromlocal(parent)
941 if not parent.startswith('<'):
946 if not parent.startswith('<'):
942 parent = '<' + parent
947 parent = '<' + parent
943 if not parent.endswith('>'):
948 if not parent.endswith('>'):
944 parent += '>'
949 parent += '>'
945
950
946 sender_addr = eutil.parseaddr(encoding.strfromlocal(sender))[1]
951 sender_addr = eutil.parseaddr(encoding.strfromlocal(sender))[1]
947 sender = mail.addressencode(ui, sender, _charsets, opts.get(b'test'))
952 sender = mail.addressencode(ui, sender, _charsets, opts.get(b'test'))
948 sendmail = None
953 sendmail = None
949 firstpatch = None
954 firstpatch = None
950 progress = ui.makeprogress(
955 progress = ui.makeprogress(
951 _(b'sending'), unit=_(b'emails'), total=len(msgs)
956 _(b'sending'), unit=_(b'emails'), total=len(msgs)
952 )
957 )
953 for i, (m, subj, ds) in enumerate(msgs):
958 for i, (m, subj, ds) in enumerate(msgs):
954 try:
959 try:
955 m['Message-Id'] = genmsgid(m['X-Mercurial-Node'])
960 m['Message-Id'] = genmsgid(m['X-Mercurial-Node'])
956 if not firstpatch:
961 if not firstpatch:
957 firstpatch = m['Message-Id']
962 firstpatch = m['Message-Id']
958 m['X-Mercurial-Series-Id'] = firstpatch
963 m['X-Mercurial-Series-Id'] = firstpatch
959 except TypeError:
964 except TypeError:
960 m['Message-Id'] = genmsgid('patchbomb')
965 m['Message-Id'] = genmsgid('patchbomb')
961 if parent:
966 if parent:
962 m['In-Reply-To'] = parent
967 m['In-Reply-To'] = parent
963 m['References'] = parent
968 m['References'] = parent
964 if not parent or 'X-Mercurial-Node' not in m:
969 if not parent or 'X-Mercurial-Node' not in m:
965 parent = m['Message-Id']
970 parent = m['Message-Id']
966
971
967 m['User-Agent'] = 'Mercurial-patchbomb/%s' % util.version().decode()
972 m['User-Agent'] = 'Mercurial-patchbomb/%s' % util.version().decode()
968 m['Date'] = eutil.formatdate(start_time[0], localtime=True)
973 m['Date'] = eutil.formatdate(start_time[0], localtime=True)
969
974
970 start_time = (start_time[0] + 1, start_time[1])
975 start_time = (start_time[0] + 1, start_time[1])
971 m['From'] = sender
976 m['From'] = sender
972 m['To'] = ', '.join(to)
977 m['To'] = ', '.join(to)
973 if cc:
978 if cc:
974 m['Cc'] = ', '.join(cc)
979 m['Cc'] = ', '.join(cc)
975 if bcc:
980 if bcc:
976 m['Bcc'] = ', '.join(bcc)
981 m['Bcc'] = ', '.join(bcc)
977 if replyto:
982 if replyto:
978 m['Reply-To'] = ', '.join(replyto)
983 m['Reply-To'] = ', '.join(replyto)
979 if opts.get(b'test'):
984 if opts.get(b'test'):
980 ui.status(_(b'displaying '), subj, b' ...\n')
985 ui.status(_(b'displaying '), subj, b' ...\n')
981 ui.pager(b'email')
986 ui.pager(b'email')
982 generator = mail.Generator(ui, mangle_from_=False)
987 generator = mail.Generator(ui, mangle_from_=False)
983 try:
988 try:
984 generator.flatten(m, False)
989 generator.flatten(m, False)
985 ui.write(b'\n')
990 ui.write(b'\n')
986 except BrokenPipeError:
991 except BrokenPipeError:
987 pass
992 pass
988 else:
993 else:
989 if not sendmail:
994 if not sendmail:
990 sendmail = mail.connect(ui, mbox=mbox)
995 sendmail = mail.connect(ui, mbox=mbox)
991 ui.status(_(b'sending '), subj, b' ...\n')
996 ui.status(_(b'sending '), subj, b' ...\n')
992 progress.update(i, item=subj)
997 progress.update(i, item=subj)
993 if not mbox:
998 if not mbox:
994 # Exim does not remove the Bcc field
999 # Exim does not remove the Bcc field
995 del m['Bcc']
1000 del m['Bcc']
996 fp = stringio()
1001 fp = stringio()
997 generator = mail.Generator(fp, mangle_from_=False)
1002 generator = mail.Generator(fp, mangle_from_=False)
998 generator.flatten(m, False)
1003 generator.flatten(m, False)
999 alldests = to + bcc + cc
1004 alldests = to + bcc + cc
1000 sendmail(sender_addr, alldests, fp.getvalue())
1005 sendmail(sender_addr, alldests, fp.getvalue())
1001
1006
1002 progress.complete()
1007 progress.complete()
@@ -1,3162 +1,3199 b''
1 Note for future hackers of patchbomb: this file is a bit heavy on
1 Note for future hackers of patchbomb: this file is a bit heavy on
2 wildcards in test expectations due to how many things like hostnames
2 wildcards in test expectations due to how many things like hostnames
3 tend to make it into outputs. As a result, you may need to perform the
3 tend to make it into outputs. As a result, you may need to perform the
4 following regular expression substitutions:
4 following regular expression substitutions:
5 Mercurial-patchbomb/.* -> Mercurial-patchbomb/* (glob)
5 Mercurial-patchbomb/.* -> Mercurial-patchbomb/* (glob)
6 /mixed; boundary="===+[0-9]+==" -> /mixed; boundary="===*== (glob)"
6 /mixed; boundary="===+[0-9]+==" -> /mixed; boundary="===*== (glob)"
7 --===+[0-9]+=+--$ -> --===*=-- (glob)
7 --===+[0-9]+=+--$ -> --===*=-- (glob)
8 --===+[0-9]+=+$ -> --===*= (glob)
8 --===+[0-9]+=+$ -> --===*= (glob)
9
9
10 $ cat > prune-blank-after-boundary.py <<EOF
10 $ cat > prune-blank-after-boundary.py <<EOF
11 > import sys
11 > import sys
12 > skipblank = False
12 > skipblank = False
13 > trim = lambda x: x.strip(' \r\n')
13 > trim = lambda x: x.strip(' \r\n')
14 > for l in sys.stdin:
14 > for l in sys.stdin:
15 > if trim(l).endswith('=--') or trim(l).endswith('=='):
15 > if trim(l).endswith('=--') or trim(l).endswith('=='):
16 > skipblank = True
16 > skipblank = True
17 > print(l, end='')
17 > print(l, end='')
18 > continue
18 > continue
19 > if not trim(l) and skipblank:
19 > if not trim(l) and skipblank:
20 > continue
20 > continue
21 > skipblank = False
21 > skipblank = False
22 > print(l, end='')
22 > print(l, end='')
23 > EOF
23 > EOF
24 $ filterboundary() {
24 $ filterboundary() {
25 > "$PYTHON" "$TESTTMP/prune-blank-after-boundary.py"
25 > "$PYTHON" "$TESTTMP/prune-blank-after-boundary.py"
26 > }
26 > }
27 $ echo "[extensions]" >> $HGRCPATH
27 $ echo "[extensions]" >> $HGRCPATH
28 $ echo "patchbomb=" >> $HGRCPATH
28 $ echo "patchbomb=" >> $HGRCPATH
29
29
30 $ hg init t
30 $ hg init t
31 $ cd t
31 $ cd t
32 $ echo a > a
32 $ echo a > a
33 $ hg commit -Ama -d '1 0'
33 $ hg commit -Ama -d '1 0'
34 adding a
34 adding a
35
35
36 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -r tip
36 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -r tip
37 this patch series consists of 1 patches.
37 this patch series consists of 1 patches.
38
38
39
39
40 displaying [PATCH] a ...
40 displaying [PATCH] a ...
41 MIME-Version: 1.0
41 MIME-Version: 1.0
42 Content-Type: text/plain; charset="us-ascii"
42 Content-Type: text/plain; charset="us-ascii"
43 Content-Transfer-Encoding: 7bit
43 Content-Transfer-Encoding: 7bit
44 Subject: [PATCH] a
44 Subject: [PATCH] a
45 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
45 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
46 X-Mercurial-Series-Index: 1
46 X-Mercurial-Series-Index: 1
47 X-Mercurial-Series-Total: 1
47 X-Mercurial-Series-Total: 1
48 Message-Id: <8580ff50825a50c8f716.60@test-hostname>
48 Message-Id: <8580ff50825a50c8f716.60@test-hostname>
49 X-Mercurial-Series-Id: <8580ff50825a50c8f716.60@test-hostname>
49 X-Mercurial-Series-Id: <8580ff50825a50c8f716.60@test-hostname>
50 User-Agent: Mercurial-patchbomb/* (glob)
50 User-Agent: Mercurial-patchbomb/* (glob)
51 Date: Thu, 01 Jan 1970 00:01:00 +0000
51 Date: Thu, 01 Jan 1970 00:01:00 +0000
52 From: quux
52 From: quux
53 To: foo
53 To: foo
54 Cc: bar
54 Cc: bar
55
55
56 # HG changeset patch
56 # HG changeset patch
57 # User test
57 # User test
58 # Date 1 0
58 # Date 1 0
59 # Thu Jan 01 00:00:01 1970 +0000
59 # Thu Jan 01 00:00:01 1970 +0000
60 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
60 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
61 # Parent 0000000000000000000000000000000000000000
61 # Parent 0000000000000000000000000000000000000000
62 a
62 a
63
63
64 diff -r 000000000000 -r 8580ff50825a a
64 diff -r 000000000000 -r 8580ff50825a a
65 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
65 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
66 +++ b/a Thu Jan 01 00:00:01 1970 +0000
66 +++ b/a Thu Jan 01 00:00:01 1970 +0000
67 @@ -0,0 +1,1 @@
67 @@ -0,0 +1,1 @@
68 +a
68 +a
69
69
70
70
71 If --to is specified on the command line, it should override any
71 If --to is specified on the command line, it should override any
72 email.to config setting. Same for --cc:
72 email.to config setting. Same for --cc:
73
73
74 $ hg email --date '1970-1-1 0:1' -n -f quux --to foo --cc bar -r tip \
74 $ hg email --date '1970-1-1 0:1' -n -f quux --to foo --cc bar -r tip \
75 > --config email.to=bob@example.com --config email.cc=alice@example.com
75 > --config email.to=bob@example.com --config email.cc=alice@example.com
76 this patch series consists of 1 patches.
76 this patch series consists of 1 patches.
77
77
78
78
79 displaying [PATCH] a ...
79 displaying [PATCH] a ...
80 MIME-Version: 1.0
80 MIME-Version: 1.0
81 Content-Type: text/plain; charset="us-ascii"
81 Content-Type: text/plain; charset="us-ascii"
82 Content-Transfer-Encoding: 7bit
82 Content-Transfer-Encoding: 7bit
83 Subject: [PATCH] a
83 Subject: [PATCH] a
84 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
84 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
85 X-Mercurial-Series-Index: 1
85 X-Mercurial-Series-Index: 1
86 X-Mercurial-Series-Total: 1
86 X-Mercurial-Series-Total: 1
87 Message-Id: <8580ff50825a50c8f716.60@test-hostname>
87 Message-Id: <8580ff50825a50c8f716.60@test-hostname>
88 X-Mercurial-Series-Id: <8580ff50825a50c8f716.60@test-hostname>
88 X-Mercurial-Series-Id: <8580ff50825a50c8f716.60@test-hostname>
89 User-Agent: Mercurial-patchbomb/* (glob)
89 User-Agent: Mercurial-patchbomb/* (glob)
90 Date: Thu, 01 Jan 1970 00:01:00 +0000
90 Date: Thu, 01 Jan 1970 00:01:00 +0000
91 From: quux
91 From: quux
92 To: foo
92 To: foo
93 Cc: bar
93 Cc: bar
94
94
95 # HG changeset patch
95 # HG changeset patch
96 # User test
96 # User test
97 # Date 1 0
97 # Date 1 0
98 # Thu Jan 01 00:00:01 1970 +0000
98 # Thu Jan 01 00:00:01 1970 +0000
99 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
99 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
100 # Parent 0000000000000000000000000000000000000000
100 # Parent 0000000000000000000000000000000000000000
101 a
101 a
102
102
103 diff -r 000000000000 -r 8580ff50825a a
103 diff -r 000000000000 -r 8580ff50825a a
104 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
104 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
105 +++ b/a Thu Jan 01 00:00:01 1970 +0000
105 +++ b/a Thu Jan 01 00:00:01 1970 +0000
106 @@ -0,0 +1,1 @@
106 @@ -0,0 +1,1 @@
107 +a
107 +a
108
108
109
109
110 $ hg --config ui.interactive=1 email --confirm -n -f quux -t foo -c bar -r tip<<EOF
110 $ hg --config ui.interactive=1 email --confirm -n -f quux -t foo -c bar -r tip<<EOF
111 > n
111 > n
112 > EOF
112 > EOF
113 this patch series consists of 1 patches.
113 this patch series consists of 1 patches.
114
114
115
115
116 Final summary:
116 Final summary:
117
117
118 From: quux
118 From: quux
119 To: foo
119 To: foo
120 Cc: bar
120 Cc: bar
121 Subject: [PATCH] a
121 Subject: [PATCH] a
122 a | 1 +
122 a | 1 +
123 1 files changed, 1 insertions(+), 0 deletions(-)
123 1 files changed, 1 insertions(+), 0 deletions(-)
124
124
125 are you sure you want to send (yn)? n
125 are you sure you want to send (yn)? n
126 abort: patchbomb canceled
126 abort: patchbomb canceled
127 [255]
127 [255]
128
128
129 $ hg --config ui.interactive=1 --config patchbomb.confirm=true email -n -f quux -t foo -c bar -r tip<<EOF
129 $ hg --config ui.interactive=1 --config patchbomb.confirm=true email -n -f quux -t foo -c bar -r tip<<EOF
130 > n
130 > n
131 > EOF
131 > EOF
132 this patch series consists of 1 patches.
132 this patch series consists of 1 patches.
133
133
134
134
135 Final summary:
135 Final summary:
136
136
137 From: quux
137 From: quux
138 To: foo
138 To: foo
139 Cc: bar
139 Cc: bar
140 Subject: [PATCH] a
140 Subject: [PATCH] a
141 a | 1 +
141 a | 1 +
142 1 files changed, 1 insertions(+), 0 deletions(-)
142 1 files changed, 1 insertions(+), 0 deletions(-)
143
143
144 are you sure you want to send (yn)? n
144 are you sure you want to send (yn)? n
145 abort: patchbomb canceled
145 abort: patchbomb canceled
146 [255]
146 [255]
147
147
148
148
149 Test diff.git is respected
149 Test diff.git is respected
150 $ hg --config diff.git=True email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -r tip
150 $ hg --config diff.git=True email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -r tip
151 this patch series consists of 1 patches.
151 this patch series consists of 1 patches.
152
152
153
153
154 displaying [PATCH] a ...
154 displaying [PATCH] a ...
155 MIME-Version: 1.0
155 MIME-Version: 1.0
156 Content-Type: text/plain; charset="us-ascii"
156 Content-Type: text/plain; charset="us-ascii"
157 Content-Transfer-Encoding: 7bit
157 Content-Transfer-Encoding: 7bit
158 Subject: [PATCH] a
158 Subject: [PATCH] a
159 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
159 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
160 X-Mercurial-Series-Index: 1
160 X-Mercurial-Series-Index: 1
161 X-Mercurial-Series-Total: 1
161 X-Mercurial-Series-Total: 1
162 Message-Id: <8580ff50825a50c8f716.60@test-hostname>
162 Message-Id: <8580ff50825a50c8f716.60@test-hostname>
163 X-Mercurial-Series-Id: <8580ff50825a50c8f716.60@test-hostname>
163 X-Mercurial-Series-Id: <8580ff50825a50c8f716.60@test-hostname>
164 User-Agent: Mercurial-patchbomb/* (glob)
164 User-Agent: Mercurial-patchbomb/* (glob)
165 Date: Thu, 01 Jan 1970 00:01:00 +0000
165 Date: Thu, 01 Jan 1970 00:01:00 +0000
166 From: quux
166 From: quux
167 To: foo
167 To: foo
168 Cc: bar
168 Cc: bar
169
169
170 # HG changeset patch
170 # HG changeset patch
171 # User test
171 # User test
172 # Date 1 0
172 # Date 1 0
173 # Thu Jan 01 00:00:01 1970 +0000
173 # Thu Jan 01 00:00:01 1970 +0000
174 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
174 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
175 # Parent 0000000000000000000000000000000000000000
175 # Parent 0000000000000000000000000000000000000000
176 a
176 a
177
177
178 diff --git a/a b/a
178 diff --git a/a b/a
179 new file mode 100644
179 new file mode 100644
180 --- /dev/null
180 --- /dev/null
181 +++ b/a
181 +++ b/a
182 @@ -0,0 +1,1 @@
182 @@ -0,0 +1,1 @@
183 +a
183 +a
184
184
185
185
186 Test --git is respected
187 $ hg email --git --date '1970-1-1 0:1' -n -f quux -t foo -c bar -r tip
188 this patch series consists of 1 patches.
189
190
191 displaying [PATCH] a ...
192 MIME-Version: 1.0
193 Content-Type: text/plain; charset="us-ascii"
194 Content-Transfer-Encoding: 7bit
195 Subject: [PATCH] a
196 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
197 X-Mercurial-Series-Index: 1
198 X-Mercurial-Series-Total: 1
199 Message-Id: <8580ff50825a50c8f716.60@test-hostname>
200 X-Mercurial-Series-Id: <8580ff50825a50c8f716.60@test-hostname>
201 User-Agent: Mercurial-patchbomb/* (glob)
202 Date: Thu, 01 Jan 1970 00:01:00 +0000
203 From: quux
204 To: foo
205 Cc: bar
206
207 # HG changeset patch
208 # User test
209 # Date 1 0
210 # Thu Jan 01 00:00:01 1970 +0000
211 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
212 # Parent 0000000000000000000000000000000000000000
213 a
214
215 diff --git a/a b/a
216 new file mode 100644
217 --- /dev/null
218 +++ b/a
219 @@ -0,0 +1,1 @@
220 +a
221
222
186
223
187 Test breaking format changes aren't
224 Test breaking format changes aren't
188 $ hg --config diff.noprefix=True email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -r tip
225 $ hg --config diff.noprefix=True email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -r tip
189 this patch series consists of 1 patches.
226 this patch series consists of 1 patches.
190
227
191
228
192 displaying [PATCH] a ...
229 displaying [PATCH] a ...
193 MIME-Version: 1.0
230 MIME-Version: 1.0
194 Content-Type: text/plain; charset="us-ascii"
231 Content-Type: text/plain; charset="us-ascii"
195 Content-Transfer-Encoding: 7bit
232 Content-Transfer-Encoding: 7bit
196 Subject: [PATCH] a
233 Subject: [PATCH] a
197 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
234 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
198 X-Mercurial-Series-Index: 1
235 X-Mercurial-Series-Index: 1
199 X-Mercurial-Series-Total: 1
236 X-Mercurial-Series-Total: 1
200 Message-Id: <8580ff50825a50c8f716.60@test-hostname>
237 Message-Id: <8580ff50825a50c8f716.60@test-hostname>
201 X-Mercurial-Series-Id: <8580ff50825a50c8f716.60@test-hostname>
238 X-Mercurial-Series-Id: <8580ff50825a50c8f716.60@test-hostname>
202 User-Agent: Mercurial-patchbomb/* (glob)
239 User-Agent: Mercurial-patchbomb/* (glob)
203 Date: Thu, 01 Jan 1970 00:01:00 +0000
240 Date: Thu, 01 Jan 1970 00:01:00 +0000
204 From: quux
241 From: quux
205 To: foo
242 To: foo
206 Cc: bar
243 Cc: bar
207
244
208 # HG changeset patch
245 # HG changeset patch
209 # User test
246 # User test
210 # Date 1 0
247 # Date 1 0
211 # Thu Jan 01 00:00:01 1970 +0000
248 # Thu Jan 01 00:00:01 1970 +0000
212 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
249 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
213 # Parent 0000000000000000000000000000000000000000
250 # Parent 0000000000000000000000000000000000000000
214 a
251 a
215
252
216 diff -r 000000000000 -r 8580ff50825a a
253 diff -r 000000000000 -r 8580ff50825a a
217 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
254 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
218 +++ b/a Thu Jan 01 00:00:01 1970 +0000
255 +++ b/a Thu Jan 01 00:00:01 1970 +0000
219 @@ -0,0 +1,1 @@
256 @@ -0,0 +1,1 @@
220 +a
257 +a
221
258
222
259
223 $ echo b > b
260 $ echo b > b
224 $ hg commit -Amb -d '2 0'
261 $ hg commit -Amb -d '2 0'
225 adding b
262 adding b
226
263
227 $ hg email --date '1970-1-1 0:2' -n -f quux -t foo -c bar -s test -r 0:tip
264 $ hg email --date '1970-1-1 0:2' -n -f quux -t foo -c bar -s test -r 0:tip
228 this patch series consists of 2 patches.
265 this patch series consists of 2 patches.
229
266
230
267
231 Write the introductory message for the patch series.
268 Write the introductory message for the patch series.
232
269
233
270
234 displaying [PATCH 0 of 2] test ...
271 displaying [PATCH 0 of 2] test ...
235 MIME-Version: 1.0
272 MIME-Version: 1.0
236 Content-Type: text/plain; charset="us-ascii"
273 Content-Type: text/plain; charset="us-ascii"
237 Content-Transfer-Encoding: 7bit
274 Content-Transfer-Encoding: 7bit
238 Subject: [PATCH 0 of 2] test
275 Subject: [PATCH 0 of 2] test
239 Message-Id: <patchbomb.120@test-hostname>
276 Message-Id: <patchbomb.120@test-hostname>
240 User-Agent: Mercurial-patchbomb/* (glob)
277 User-Agent: Mercurial-patchbomb/* (glob)
241 Date: Thu, 01 Jan 1970 00:02:00 +0000
278 Date: Thu, 01 Jan 1970 00:02:00 +0000
242 From: quux
279 From: quux
243 To: foo
280 To: foo
244 Cc: bar
281 Cc: bar
245
282
246
283
247 displaying [PATCH 1 of 2] a ...
284 displaying [PATCH 1 of 2] a ...
248 MIME-Version: 1.0
285 MIME-Version: 1.0
249 Content-Type: text/plain; charset="us-ascii"
286 Content-Type: text/plain; charset="us-ascii"
250 Content-Transfer-Encoding: 7bit
287 Content-Transfer-Encoding: 7bit
251 Subject: [PATCH 1 of 2] a
288 Subject: [PATCH 1 of 2] a
252 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
289 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
253 X-Mercurial-Series-Index: 1
290 X-Mercurial-Series-Index: 1
254 X-Mercurial-Series-Total: 2
291 X-Mercurial-Series-Total: 2
255 Message-Id: <8580ff50825a50c8f716.121@test-hostname>
292 Message-Id: <8580ff50825a50c8f716.121@test-hostname>
256 X-Mercurial-Series-Id: <8580ff50825a50c8f716.121@test-hostname>
293 X-Mercurial-Series-Id: <8580ff50825a50c8f716.121@test-hostname>
257 In-Reply-To: <patchbomb.120@test-hostname>
294 In-Reply-To: <patchbomb.120@test-hostname>
258 References: <patchbomb.120@test-hostname>
295 References: <patchbomb.120@test-hostname>
259 User-Agent: Mercurial-patchbomb/* (glob)
296 User-Agent: Mercurial-patchbomb/* (glob)
260 Date: Thu, 01 Jan 1970 00:02:01 +0000
297 Date: Thu, 01 Jan 1970 00:02:01 +0000
261 From: quux
298 From: quux
262 To: foo
299 To: foo
263 Cc: bar
300 Cc: bar
264
301
265 # HG changeset patch
302 # HG changeset patch
266 # User test
303 # User test
267 # Date 1 0
304 # Date 1 0
268 # Thu Jan 01 00:00:01 1970 +0000
305 # Thu Jan 01 00:00:01 1970 +0000
269 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
306 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
270 # Parent 0000000000000000000000000000000000000000
307 # Parent 0000000000000000000000000000000000000000
271 a
308 a
272
309
273 diff -r 000000000000 -r 8580ff50825a a
310 diff -r 000000000000 -r 8580ff50825a a
274 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
311 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
275 +++ b/a Thu Jan 01 00:00:01 1970 +0000
312 +++ b/a Thu Jan 01 00:00:01 1970 +0000
276 @@ -0,0 +1,1 @@
313 @@ -0,0 +1,1 @@
277 +a
314 +a
278
315
279 displaying [PATCH 2 of 2] b ...
316 displaying [PATCH 2 of 2] b ...
280 MIME-Version: 1.0
317 MIME-Version: 1.0
281 Content-Type: text/plain; charset="us-ascii"
318 Content-Type: text/plain; charset="us-ascii"
282 Content-Transfer-Encoding: 7bit
319 Content-Transfer-Encoding: 7bit
283 Subject: [PATCH 2 of 2] b
320 Subject: [PATCH 2 of 2] b
284 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
321 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
285 X-Mercurial-Series-Index: 2
322 X-Mercurial-Series-Index: 2
286 X-Mercurial-Series-Total: 2
323 X-Mercurial-Series-Total: 2
287 Message-Id: <97d72e5f12c7e84f8506.122@test-hostname>
324 Message-Id: <97d72e5f12c7e84f8506.122@test-hostname>
288 X-Mercurial-Series-Id: <8580ff50825a50c8f716.121@test-hostname>
325 X-Mercurial-Series-Id: <8580ff50825a50c8f716.121@test-hostname>
289 In-Reply-To: <patchbomb.120@test-hostname>
326 In-Reply-To: <patchbomb.120@test-hostname>
290 References: <patchbomb.120@test-hostname>
327 References: <patchbomb.120@test-hostname>
291 User-Agent: Mercurial-patchbomb/* (glob)
328 User-Agent: Mercurial-patchbomb/* (glob)
292 Date: Thu, 01 Jan 1970 00:02:02 +0000
329 Date: Thu, 01 Jan 1970 00:02:02 +0000
293 From: quux
330 From: quux
294 To: foo
331 To: foo
295 Cc: bar
332 Cc: bar
296
333
297 # HG changeset patch
334 # HG changeset patch
298 # User test
335 # User test
299 # Date 2 0
336 # Date 2 0
300 # Thu Jan 01 00:00:02 1970 +0000
337 # Thu Jan 01 00:00:02 1970 +0000
301 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
338 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
302 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
339 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
303 b
340 b
304
341
305 diff -r 8580ff50825a -r 97d72e5f12c7 b
342 diff -r 8580ff50825a -r 97d72e5f12c7 b
306 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
343 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
307 +++ b/b Thu Jan 01 00:00:02 1970 +0000
344 +++ b/b Thu Jan 01 00:00:02 1970 +0000
308 @@ -0,0 +1,1 @@
345 @@ -0,0 +1,1 @@
309 +b
346 +b
310
347
311
348
312 .hg/last-email.txt
349 .hg/last-email.txt
313
350
314 $ cat > editor.sh << '__EOF__'
351 $ cat > editor.sh << '__EOF__'
315 > echo "a precious introductory message" > "$1"
352 > echo "a precious introductory message" > "$1"
316 > __EOF__
353 > __EOF__
317 $ HGEDITOR="\"sh\" \"`pwd`/editor.sh\"" hg email -n -t foo -s test -r 0:tip > /dev/null
354 $ HGEDITOR="\"sh\" \"`pwd`/editor.sh\"" hg email -n -t foo -s test -r 0:tip > /dev/null
318 $ cat .hg/last-email.txt
355 $ cat .hg/last-email.txt
319 a precious introductory message
356 a precious introductory message
320
357
321 $ hg email -m test.mbox -f quux -t foo -c bar -s test 0:tip \
358 $ hg email -m test.mbox -f quux -t foo -c bar -s test 0:tip \
322 > --config extensions.progress= --config progress.assume-tty=1 \
359 > --config extensions.progress= --config progress.assume-tty=1 \
323 > --config progress.delay=0 --config progress.refresh=0 \
360 > --config progress.delay=0 --config progress.refresh=0 \
324 > --config progress.width=60 \
361 > --config progress.width=60 \
325 > --config extensions.mocktime=$TESTDIR/mocktime.py
362 > --config extensions.mocktime=$TESTDIR/mocktime.py
326 this patch series consists of 2 patches.
363 this patch series consists of 2 patches.
327
364
328
365
329 Write the introductory message for the patch series.
366 Write the introductory message for the patch series.
330
367
331 \r (no-eol) (esc)
368 \r (no-eol) (esc)
332 sending [ ] 0/3\r (no-eol) (esc)
369 sending [ ] 0/3\r (no-eol) (esc)
333 \r (no-eol) (esc)
370 \r (no-eol) (esc)
334 \r (no-eol) (esc)
371 \r (no-eol) (esc)
335 sending [============> ] 1/3 01s\r (no-eol) (esc)
372 sending [============> ] 1/3 01s\r (no-eol) (esc)
336 \r (no-eol) (esc)
373 \r (no-eol) (esc)
337 \r (no-eol) (esc)
374 \r (no-eol) (esc)
338 sending [==========================> ] 2/3 01s\r (no-eol) (esc)
375 sending [==========================> ] 2/3 01s\r (no-eol) (esc)
339 \r (esc)
376 \r (esc)
340 sending [PATCH 0 of 2] test ...
377 sending [PATCH 0 of 2] test ...
341 sending [PATCH 1 of 2] a ...
378 sending [PATCH 1 of 2] a ...
342 sending [PATCH 2 of 2] b ...
379 sending [PATCH 2 of 2] b ...
343
380
344 $ cd ..
381 $ cd ..
345
382
346 $ hg clone -q t t2
383 $ hg clone -q t t2
347 $ cd t2
384 $ cd t2
348 $ echo c > c
385 $ echo c > c
349 $ hg commit -Amc -d '3 0'
386 $ hg commit -Amc -d '3 0'
350 adding c
387 adding c
351
388
352 $ cat > description <<EOF
389 $ cat > description <<EOF
353 > a multiline
390 > a multiline
354 >
391 >
355 > description
392 > description
356 > EOF
393 > EOF
357
394
358
395
359 test bundle and description:
396 test bundle and description:
360 $ hg email --date '1970-1-1 0:3' -n -f quux -t foo \
397 $ hg email --date '1970-1-1 0:3' -n -f quux -t foo \
361 > -c bar -s test -r tip -b --desc description | filterboundary
398 > -c bar -s test -r tip -b --desc description | filterboundary
362 searching for changes
399 searching for changes
363 1 changesets found
400 1 changesets found
364
401
365 displaying test ...
402 displaying test ...
366 Content-Type: multipart/mixed; boundary="===*==" (glob)
403 Content-Type: multipart/mixed; boundary="===*==" (glob)
367 MIME-Version: 1.0
404 MIME-Version: 1.0
368 Subject: test
405 Subject: test
369 Message-Id: <patchbomb.180@test-hostname>
406 Message-Id: <patchbomb.180@test-hostname>
370 User-Agent: Mercurial-patchbomb/* (glob)
407 User-Agent: Mercurial-patchbomb/* (glob)
371 Date: Thu, 01 Jan 1970 00:03:00 +0000
408 Date: Thu, 01 Jan 1970 00:03:00 +0000
372 From: quux
409 From: quux
373 To: foo
410 To: foo
374 Cc: bar
411 Cc: bar
375
412
376 --===*= (glob)
413 --===*= (glob)
377 MIME-Version: 1.0
414 MIME-Version: 1.0
378 Content-Type: text/plain; charset="us-ascii"
415 Content-Type: text/plain; charset="us-ascii"
379 Content-Transfer-Encoding: 7bit
416 Content-Transfer-Encoding: 7bit
380
417
381 a multiline
418 a multiline
382
419
383 description
420 description
384
421
385 --===*= (glob)
422 --===*= (glob)
386 Content-Type: application/x-mercurial-bundle
423 Content-Type: application/x-mercurial-bundle
387 MIME-Version: 1.0
424 MIME-Version: 1.0
388 Content-Disposition: attachment; filename="bundle.hg"
425 Content-Disposition: attachment; filename="bundle.hg"
389 Content-Transfer-Encoding: base64
426 Content-Transfer-Encoding: base64
390
427
391 SEcyMAAAAA5Db21wcmVzc2lvbj1CWkJaaDkxQVkmU1l91TAVAAAN////vFcSXL9/8H7R09C/578I
428 SEcyMAAAAA5Db21wcmVzc2lvbj1CWkJaaDkxQVkmU1l91TAVAAAN////vFcSXL9/8H7R09C/578I
392 Ak0E4pe4SIIIgQSgGEQOcLABGYYNKgJgmhpp6mmjIZMCZNMhpgBBpkaYJpo9QaZMg02iaY2lCImK
429 Ak0E4pe4SIIIgQSgGEQOcLABGYYNKgJgmhpp6mmjIZMCZNMhpgBBpkaYJpo9QaZMg02iaY2lCImK
393 emk02kmEAeoA0D01ANBoHqHqADTaj1NAAyZqA0Gg0KiYnqaepk0eoNDTCGj1A0eoyBoGjRkYBqAB
430 emk02kmEAeoA0D01ANBoHqHqADTaj1NAAyZqA0Gg0KiYnqaepk0eoNDTCGj1A0eoyBoGjRkYBqAB
394 poNMmhkBhENSP0knlYZbqyEIYxkFdpDUS6roBDMgAGhkAqd92kEcgyeMo2MM366gpLNHjfKrhJPN
431 poNMmhkBhENSP0knlYZbqyEIYxkFdpDUS6roBDMgAGhkAqd92kEcgyeMo2MM366gpLNHjfKrhJPN
395 vdBCHAEDsYzAvzkHKxy5KWBAmh5e1nFttGChpsxrgmutRG0YrsSLWEBH9h95cbZEKFeUKYykRXHa
432 vdBCHAEDsYzAvzkHKxy5KWBAmh5e1nFttGChpsxrgmutRG0YrsSLWEBH9h95cbZEKFeUKYykRXHa
396 Bkt2OSgELsqqnWKeMudBR+YSZCOSHrwPz7B/Gfou7/L6QV6S0IgclBCitBVHMxMFq/vGwp5WHezM
433 Bkt2OSgELsqqnWKeMudBR+YSZCOSHrwPz7B/Gfou7/L6QV6S0IgclBCitBVHMxMFq/vGwp5WHezM
397 JwhKTnH0OkMbmVjrAkQKR7VM2aNSXn+GzLOCzOQm0AJ1TLCpdSgnfFPcY7mGxAOyHXS1YEFVi5O9
434 JwhKTnH0OkMbmVjrAkQKR7VM2aNSXn+GzLOCzOQm0AJ1TLCpdSgnfFPcY7mGxAOyHXS1YEFVi5O9
398 I4EVBBd8VRgN4n1MAm8l6QQ+yB60hkeX/0ZZmKoQRINkEBxEDZU2HjIZMcwWRvZtbRIa5kgkGIb/
435 I4EVBBd8VRgN4n1MAm8l6QQ+yB60hkeX/0ZZmKoQRINkEBxEDZU2HjIZMcwWRvZtbRIa5kgkGIb/
399 SkImFwIkDtQxyX+LuSKcKEg+6pgKgA==
436 SkImFwIkDtQxyX+LuSKcKEg+6pgKgA==
400 --===============*==-- (glob)
437 --===============*==-- (glob)
401
438
402 with a specific bundle type
439 with a specific bundle type
403 (binary part must be different)
440 (binary part must be different)
404
441
405 $ hg email --date '1970-1-1 0:3' -n -f quux -t foo \
442 $ hg email --date '1970-1-1 0:3' -n -f quux -t foo \
406 > -c bar -s test -r tip -b --desc description \
443 > -c bar -s test -r tip -b --desc description \
407 > --config patchbomb.bundletype=gzip-v1 | filterboundary
444 > --config patchbomb.bundletype=gzip-v1 | filterboundary
408 searching for changes
445 searching for changes
409 1 changesets found
446 1 changesets found
410
447
411 displaying test ...
448 displaying test ...
412 Content-Type: multipart/mixed; boundary="===*==" (glob)
449 Content-Type: multipart/mixed; boundary="===*==" (glob)
413 MIME-Version: 1.0
450 MIME-Version: 1.0
414 Subject: test
451 Subject: test
415 Message-Id: <patchbomb.180@test-hostname>
452 Message-Id: <patchbomb.180@test-hostname>
416 User-Agent: Mercurial-patchbomb/* (glob)
453 User-Agent: Mercurial-patchbomb/* (glob)
417 Date: Thu, 01 Jan 1970 00:03:00 +0000
454 Date: Thu, 01 Jan 1970 00:03:00 +0000
418 From: quux
455 From: quux
419 To: foo
456 To: foo
420 Cc: bar
457 Cc: bar
421
458
422 --===*= (glob)
459 --===*= (glob)
423 MIME-Version: 1.0
460 MIME-Version: 1.0
424 Content-Type: text/plain; charset="us-ascii"
461 Content-Type: text/plain; charset="us-ascii"
425 Content-Transfer-Encoding: 7bit
462 Content-Transfer-Encoding: 7bit
426
463
427 a multiline
464 a multiline
428
465
429 description
466 description
430
467
431 --===*= (glob)
468 --===*= (glob)
432 Content-Type: application/x-mercurial-bundle
469 Content-Type: application/x-mercurial-bundle
433 MIME-Version: 1.0
470 MIME-Version: 1.0
434 Content-Disposition: attachment; filename="bundle.hg"
471 Content-Disposition: attachment; filename="bundle.hg"
435 Content-Transfer-Encoding: base64
472 Content-Transfer-Encoding: base64
436
473
437 SEcxMEdaeJxjYGBY8V9n/iLGbtFfJZuNk/euDCpWfrRy/vTrevFCx1/4t7J5LdeL0ix0Opx3kwEL
474 SEcxMEdaeJxjYGBY8V9n/iLGbtFfJZuNk/euDCpWfrRy/vTrevFCx1/4t7J5LdeL0ix0Opx3kwEL
438 wKYXKqUJwqnG5sYWSWmmJsaWlqYWaRaWJpaWiWamZpYWRgZGxolJiabmSQbmZqlcQMV6QGwCxGzG
475 wKYXKqUJwqnG5sYWSWmmJsaWlqYWaRaWJpaWiWamZpYWRgZGxolJiabmSQbmZqlcQMV6QGwCxGzG
439 CgZcySARUyA2A2LGZKiZ3Y+Lu786z4z4MWXmsrAZCsqrl1az5y21PMcjpbThzWeXGT+/nutbmvvz
476 CgZcySARUyA2A2LGZKiZ3Y+Lu786z4z4MWXmsrAZCsqrl1az5y21PMcjpbThzWeXGT+/nutbmvvz
440 zXYS3BoGxdrJDIYmlimJJiZpRokmqYYmaSYWFknmSSkmhqbmliamiZYWxuYmBhbJBgZcUBNZQe5K
477 zXYS3BoGxdrJDIYmlimJJiZpRokmqYYmaSYWFknmSSkmhqbmliamiZYWxuYmBhbJBgZcUBNZQe5K
441 Epm7xF/LT+RLx/a9juFTomaYO/Rgsx4rwBN+IMCUDLOKAQBrsmti
478 Epm7xF/LT+RLx/a9juFTomaYO/Rgsx4rwBN+IMCUDLOKAQBrsmti
442 (?)
479 (?)
443 --===============*==-- (glob)
480 --===============*==-- (glob)
444
481
445 utf-8 patch:
482 utf-8 patch:
446 $ "$PYTHON" -c 'fp = open("utf", "wb"); fp.write(b"h\xC3\xB6mma!\n"); fp.close();'
483 $ "$PYTHON" -c 'fp = open("utf", "wb"); fp.write(b"h\xC3\xB6mma!\n"); fp.close();'
447 $ hg commit -A -d '4 0' \
484 $ hg commit -A -d '4 0' \
448 > --encoding "utf-8" \
485 > --encoding "utf-8" \
449 > -m `"$PYTHON" -c 'import sys; getattr(sys.stdout, "buffer", sys.stdout).write(b"\xc3\xa7a")'`
486 > -m `"$PYTHON" -c 'import sys; getattr(sys.stdout, "buffer", sys.stdout).write(b"\xc3\xa7a")'`
450 adding description
487 adding description
451 adding utf
488 adding utf
452
489
453 no mime encoding for email --test:
490 no mime encoding for email --test:
454 $ hg email --date '1970-1-1 0:4' -f quux -t foo -c bar -r tip -n
491 $ hg email --date '1970-1-1 0:4' -f quux -t foo -c bar -r tip -n
455 this patch series consists of 1 patches.
492 this patch series consists of 1 patches.
456
493
457
494
458 displaying [PATCH] ?a ...
495 displaying [PATCH] ?a ...
459 MIME-Version: 1.0
496 MIME-Version: 1.0
460 Content-Type: text/plain; charset="iso-8859-1"
497 Content-Type: text/plain; charset="iso-8859-1"
461 Content-Transfer-Encoding: quoted-printable
498 Content-Transfer-Encoding: quoted-printable
462 Subject: [PATCH] ?a
499 Subject: [PATCH] ?a
463 X-Mercurial-Node: f81ef97829467e868fc405fccbcfa66217e4d3e6
500 X-Mercurial-Node: f81ef97829467e868fc405fccbcfa66217e4d3e6
464 X-Mercurial-Series-Index: 1
501 X-Mercurial-Series-Index: 1
465 X-Mercurial-Series-Total: 1
502 X-Mercurial-Series-Total: 1
466 Message-Id: <f81ef97829467e868fc4.240@test-hostname>
503 Message-Id: <f81ef97829467e868fc4.240@test-hostname>
467 X-Mercurial-Series-Id: <f81ef97829467e868fc4.240@test-hostname>
504 X-Mercurial-Series-Id: <f81ef97829467e868fc4.240@test-hostname>
468 User-Agent: Mercurial-patchbomb/* (glob)
505 User-Agent: Mercurial-patchbomb/* (glob)
469 Date: Thu, 01 Jan 1970 00:04:00 +0000
506 Date: Thu, 01 Jan 1970 00:04:00 +0000
470 From: quux
507 From: quux
471 To: foo
508 To: foo
472 Cc: bar
509 Cc: bar
473
510
474 # HG changeset patch
511 # HG changeset patch
475 # User test
512 # User test
476 # Date 4 0
513 # Date 4 0
477 # Thu Jan 01 00:00:04 1970 +0000
514 # Thu Jan 01 00:00:04 1970 +0000
478 # Node ID f81ef97829467e868fc405fccbcfa66217e4d3e6
515 # Node ID f81ef97829467e868fc405fccbcfa66217e4d3e6
479 # Parent ff2c9fa2018b15fa74b33363bda9527323e2a99f
516 # Parent ff2c9fa2018b15fa74b33363bda9527323e2a99f
480 ?a
517 ?a
481
518
482 diff -r ff2c9fa2018b -r f81ef9782946 description
519 diff -r ff2c9fa2018b -r f81ef9782946 description
483 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
520 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
484 +++ b/description Thu Jan 01 00:00:04 1970 +0000
521 +++ b/description Thu Jan 01 00:00:04 1970 +0000
485 @@ -0,0 +1,3 @@
522 @@ -0,0 +1,3 @@
486 +a multiline
523 +a multiline
487 +
524 +
488 +description
525 +description
489 diff -r ff2c9fa2018b -r f81ef9782946 utf
526 diff -r ff2c9fa2018b -r f81ef9782946 utf
490 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
527 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
491 +++ b/utf Thu Jan 01 00:00:04 1970 +0000
528 +++ b/utf Thu Jan 01 00:00:04 1970 +0000
492 @@ -0,0 +1,1 @@
529 @@ -0,0 +1,1 @@
493 +h=C3=B6mma!
530 +h=C3=B6mma!
494
531
495
532
496 mime encoded mbox (base64):
533 mime encoded mbox (base64):
497 $ hg email --date '1970-1-1 0:4' -f 'Q <quux>' -t foo -c bar -r tip -m mbox
534 $ hg email --date '1970-1-1 0:4' -f 'Q <quux>' -t foo -c bar -r tip -m mbox
498 this patch series consists of 1 patches.
535 this patch series consists of 1 patches.
499
536
500
537
501 sending [PATCH] ?a ...
538 sending [PATCH] ?a ...
502
539
503 $ cat mbox
540 $ cat mbox
504 From quux ... ... .. ..:..:.. .... (re)
541 From quux ... ... .. ..:..:.. .... (re)
505 MIME-Version: 1.0
542 MIME-Version: 1.0
506 Content-Type: text/plain; charset="utf-8"
543 Content-Type: text/plain; charset="utf-8"
507 Content-Transfer-Encoding: base64
544 Content-Transfer-Encoding: base64
508 Subject: [PATCH] ?a
545 Subject: [PATCH] ?a
509 X-Mercurial-Node: f81ef97829467e868fc405fccbcfa66217e4d3e6
546 X-Mercurial-Node: f81ef97829467e868fc405fccbcfa66217e4d3e6
510 X-Mercurial-Series-Index: 1
547 X-Mercurial-Series-Index: 1
511 X-Mercurial-Series-Total: 1
548 X-Mercurial-Series-Total: 1
512 Message-Id: <f81ef97829467e868fc4.240@test-hostname>
549 Message-Id: <f81ef97829467e868fc4.240@test-hostname>
513 X-Mercurial-Series-Id: <f81ef97829467e868fc4.240@test-hostname>
550 X-Mercurial-Series-Id: <f81ef97829467e868fc4.240@test-hostname>
514 User-Agent: Mercurial-patchbomb/* (glob)
551 User-Agent: Mercurial-patchbomb/* (glob)
515 Date: Thu, 01 Jan 1970 00:04:00 +0000
552 Date: Thu, 01 Jan 1970 00:04:00 +0000
516 From: =?iso-8859-1?q?Q?= <quux> (py3 !)
553 From: =?iso-8859-1?q?Q?= <quux> (py3 !)
517 To: foo
554 To: foo
518 Cc: bar
555 Cc: bar
519
556
520 IyBIRyBjaGFuZ2VzZXQgcGF0Y2gKIyBVc2VyIHRlc3QKIyBEYXRlIDQgMAojICAgICAgVGh1IEph
557 IyBIRyBjaGFuZ2VzZXQgcGF0Y2gKIyBVc2VyIHRlc3QKIyBEYXRlIDQgMAojICAgICAgVGh1IEph
521 biAwMSAwMDowMDowNCAxOTcwICswMDAwCiMgTm9kZSBJRCBmODFlZjk3ODI5NDY3ZTg2OGZjNDA1
558 biAwMSAwMDowMDowNCAxOTcwICswMDAwCiMgTm9kZSBJRCBmODFlZjk3ODI5NDY3ZTg2OGZjNDA1
522 ZmNjYmNmYTY2MjE3ZTRkM2U2CiMgUGFyZW50ICBmZjJjOWZhMjAxOGIxNWZhNzRiMzMzNjNiZGE5
559 ZmNjYmNmYTY2MjE3ZTRkM2U2CiMgUGFyZW50ICBmZjJjOWZhMjAxOGIxNWZhNzRiMzMzNjNiZGE5
523 NTI3MzIzZTJhOTlmCj9hCgpkaWZmIC1yIGZmMmM5ZmEyMDE4YiAtciBmODFlZjk3ODI5NDYgZGVz
560 NTI3MzIzZTJhOTlmCj9hCgpkaWZmIC1yIGZmMmM5ZmEyMDE4YiAtciBmODFlZjk3ODI5NDYgZGVz
524 Y3JpcHRpb24KLS0tIC9kZXYvbnVsbAlUaHUgSmFuIDAxIDAwOjAwOjAwIDE5NzAgKzAwMDAKKysr
561 Y3JpcHRpb24KLS0tIC9kZXYvbnVsbAlUaHUgSmFuIDAxIDAwOjAwOjAwIDE5NzAgKzAwMDAKKysr
525 IGIvZGVzY3JpcHRpb24JVGh1IEphbiAwMSAwMDowMDowNCAxOTcwICswMDAwCkBAIC0wLDAgKzEs
562 IGIvZGVzY3JpcHRpb24JVGh1IEphbiAwMSAwMDowMDowNCAxOTcwICswMDAwCkBAIC0wLDAgKzEs
526 MyBAQAorYSBtdWx0aWxpbmUKKworZGVzY3JpcHRpb24KZGlmZiAtciBmZjJjOWZhMjAxOGIgLXIg
563 MyBAQAorYSBtdWx0aWxpbmUKKworZGVzY3JpcHRpb24KZGlmZiAtciBmZjJjOWZhMjAxOGIgLXIg
527 ZjgxZWY5NzgyOTQ2IHV0ZgotLS0gL2Rldi9udWxsCVRodSBKYW4gMDEgMDA6MDA6MDAgMTk3MCAr
564 ZjgxZWY5NzgyOTQ2IHV0ZgotLS0gL2Rldi9udWxsCVRodSBKYW4gMDEgMDA6MDA6MDAgMTk3MCAr
528 MDAwMAorKysgYi91dGYJVGh1IEphbiAwMSAwMDowMDowNCAxOTcwICswMDAwCkBAIC0wLDAgKzEs
565 MDAwMAorKysgYi91dGYJVGh1IEphbiAwMSAwMDowMDowNCAxOTcwICswMDAwCkBAIC0wLDAgKzEs
529 MSBAQAoraMO2bW1hIQo=
566 MSBAQAoraMO2bW1hIQo=
530
567
531
568
532 >>> import base64
569 >>> import base64
533 >>> patch = base64.b64decode(open("mbox").read().split("\n\n")[1])
570 >>> patch = base64.b64decode(open("mbox").read().split("\n\n")[1])
534 >>> if not isinstance(patch, str):
571 >>> if not isinstance(patch, str):
535 ... import sys
572 ... import sys
536 ... sys.stdout.flush()
573 ... sys.stdout.flush()
537 ... junk = sys.stdout.buffer.write(patch + b"\n")
574 ... junk = sys.stdout.buffer.write(patch + b"\n")
538 ... else:
575 ... else:
539 ... print(patch)
576 ... print(patch)
540 # HG changeset patch
577 # HG changeset patch
541 # User test
578 # User test
542 # Date 4 0
579 # Date 4 0
543 # Thu Jan 01 00:00:04 1970 +0000
580 # Thu Jan 01 00:00:04 1970 +0000
544 # Node ID f81ef97829467e868fc405fccbcfa66217e4d3e6
581 # Node ID f81ef97829467e868fc405fccbcfa66217e4d3e6
545 # Parent ff2c9fa2018b15fa74b33363bda9527323e2a99f
582 # Parent ff2c9fa2018b15fa74b33363bda9527323e2a99f
546 ?a
583 ?a
547
584
548 diff -r ff2c9fa2018b -r f81ef9782946 description
585 diff -r ff2c9fa2018b -r f81ef9782946 description
549 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
586 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
550 +++ b/description Thu Jan 01 00:00:04 1970 +0000
587 +++ b/description Thu Jan 01 00:00:04 1970 +0000
551 @@ -0,0 +1,3 @@
588 @@ -0,0 +1,3 @@
552 +a multiline
589 +a multiline
553 +
590 +
554 +description
591 +description
555 diff -r ff2c9fa2018b -r f81ef9782946 utf
592 diff -r ff2c9fa2018b -r f81ef9782946 utf
556 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
593 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
557 +++ b/utf Thu Jan 01 00:00:04 1970 +0000
594 +++ b/utf Thu Jan 01 00:00:04 1970 +0000
558 @@ -0,0 +1,1 @@
595 @@ -0,0 +1,1 @@
559 +h\xc3\xb6mma! (esc)
596 +h\xc3\xb6mma! (esc)
560
597
561 $ rm mbox
598 $ rm mbox
562
599
563 mime encoded mbox (quoted-printable):
600 mime encoded mbox (quoted-printable):
564 $ "$PYTHON" -c 'fp = open("long", "wb"); fp.write(b"%s\nfoo\n\nbar\n" % (b"x" * 1024)); fp.close();'
601 $ "$PYTHON" -c 'fp = open("long", "wb"); fp.write(b"%s\nfoo\n\nbar\n" % (b"x" * 1024)); fp.close();'
565 $ hg commit -A -d '4 0' -m 'long line'
602 $ hg commit -A -d '4 0' -m 'long line'
566 adding long
603 adding long
567
604
568 no mime encoding for email --test:
605 no mime encoding for email --test:
569 $ hg email --date '1970-1-1 0:4' -f quux -t foo -c bar -r tip -n
606 $ hg email --date '1970-1-1 0:4' -f quux -t foo -c bar -r tip -n
570 this patch series consists of 1 patches.
607 this patch series consists of 1 patches.
571
608
572
609
573 displaying [PATCH] long line ...
610 displaying [PATCH] long line ...
574 MIME-Version: 1.0
611 MIME-Version: 1.0
575 Content-Type: text/plain; charset="us-ascii"
612 Content-Type: text/plain; charset="us-ascii"
576 Content-Transfer-Encoding: quoted-printable
613 Content-Transfer-Encoding: quoted-printable
577 Subject: [PATCH] long line
614 Subject: [PATCH] long line
578 X-Mercurial-Node: 0c7b871cb86b61a1c07e244393603c361e4a178d
615 X-Mercurial-Node: 0c7b871cb86b61a1c07e244393603c361e4a178d
579 X-Mercurial-Series-Index: 1
616 X-Mercurial-Series-Index: 1
580 X-Mercurial-Series-Total: 1
617 X-Mercurial-Series-Total: 1
581 Message-Id: <0c7b871cb86b61a1c07e.240@test-hostname>
618 Message-Id: <0c7b871cb86b61a1c07e.240@test-hostname>
582 X-Mercurial-Series-Id: <0c7b871cb86b61a1c07e.240@test-hostname>
619 X-Mercurial-Series-Id: <0c7b871cb86b61a1c07e.240@test-hostname>
583 User-Agent: Mercurial-patchbomb/* (glob)
620 User-Agent: Mercurial-patchbomb/* (glob)
584 Date: Thu, 01 Jan 1970 00:04:00 +0000
621 Date: Thu, 01 Jan 1970 00:04:00 +0000
585 From: quux
622 From: quux
586 To: foo
623 To: foo
587 Cc: bar
624 Cc: bar
588
625
589 # HG changeset patch
626 # HG changeset patch
590 # User test
627 # User test
591 # Date 4 0
628 # Date 4 0
592 # Thu Jan 01 00:00:04 1970 +0000
629 # Thu Jan 01 00:00:04 1970 +0000
593 # Node ID 0c7b871cb86b61a1c07e244393603c361e4a178d
630 # Node ID 0c7b871cb86b61a1c07e244393603c361e4a178d
594 # Parent f81ef97829467e868fc405fccbcfa66217e4d3e6
631 # Parent f81ef97829467e868fc405fccbcfa66217e4d3e6
595 long line
632 long line
596
633
597 diff -r f81ef9782946 -r 0c7b871cb86b long
634 diff -r f81ef9782946 -r 0c7b871cb86b long
598 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
635 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
599 +++ b/long Thu Jan 01 00:00:04 1970 +0000
636 +++ b/long Thu Jan 01 00:00:04 1970 +0000
600 @@ -0,0 +1,4 @@
637 @@ -0,0 +1,4 @@
601 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
638 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
602 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
639 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
603 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
640 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
604 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
641 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
605 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
642 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
606 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
643 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
607 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
644 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
608 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
645 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
609 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
646 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
610 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
647 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
611 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
648 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
612 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
649 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
613 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
650 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
614 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
651 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
615 +foo
652 +foo
616 +
653 +
617 +bar
654 +bar
618
655
619
656
620 mime encoded mbox (quoted-printable):
657 mime encoded mbox (quoted-printable):
621 $ hg email --date '1970-1-1 0:4' -f quux -t foo -c bar -r tip -m mbox
658 $ hg email --date '1970-1-1 0:4' -f quux -t foo -c bar -r tip -m mbox
622 this patch series consists of 1 patches.
659 this patch series consists of 1 patches.
623
660
624
661
625 sending [PATCH] long line ...
662 sending [PATCH] long line ...
626 $ cat mbox
663 $ cat mbox
627 From quux ... ... .. ..:..:.. .... (re)
664 From quux ... ... .. ..:..:.. .... (re)
628 MIME-Version: 1.0
665 MIME-Version: 1.0
629 Content-Type: text/plain; charset="us-ascii"
666 Content-Type: text/plain; charset="us-ascii"
630 Content-Transfer-Encoding: quoted-printable
667 Content-Transfer-Encoding: quoted-printable
631 Subject: [PATCH] long line
668 Subject: [PATCH] long line
632 X-Mercurial-Node: 0c7b871cb86b61a1c07e244393603c361e4a178d
669 X-Mercurial-Node: 0c7b871cb86b61a1c07e244393603c361e4a178d
633 X-Mercurial-Series-Index: 1
670 X-Mercurial-Series-Index: 1
634 X-Mercurial-Series-Total: 1
671 X-Mercurial-Series-Total: 1
635 Message-Id: <0c7b871cb86b61a1c07e.240@test-hostname>
672 Message-Id: <0c7b871cb86b61a1c07e.240@test-hostname>
636 X-Mercurial-Series-Id: <0c7b871cb86b61a1c07e.240@test-hostname>
673 X-Mercurial-Series-Id: <0c7b871cb86b61a1c07e.240@test-hostname>
637 User-Agent: Mercurial-patchbomb/* (glob)
674 User-Agent: Mercurial-patchbomb/* (glob)
638 Date: Thu, 01 Jan 1970 00:04:00 +0000
675 Date: Thu, 01 Jan 1970 00:04:00 +0000
639 From: quux
676 From: quux
640 To: foo
677 To: foo
641 Cc: bar
678 Cc: bar
642
679
643 # HG changeset patch
680 # HG changeset patch
644 # User test
681 # User test
645 # Date 4 0
682 # Date 4 0
646 # Thu Jan 01 00:00:04 1970 +0000
683 # Thu Jan 01 00:00:04 1970 +0000
647 # Node ID 0c7b871cb86b61a1c07e244393603c361e4a178d
684 # Node ID 0c7b871cb86b61a1c07e244393603c361e4a178d
648 # Parent f81ef97829467e868fc405fccbcfa66217e4d3e6
685 # Parent f81ef97829467e868fc405fccbcfa66217e4d3e6
649 long line
686 long line
650
687
651 diff -r f81ef9782946 -r 0c7b871cb86b long
688 diff -r f81ef9782946 -r 0c7b871cb86b long
652 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
689 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
653 +++ b/long Thu Jan 01 00:00:04 1970 +0000
690 +++ b/long Thu Jan 01 00:00:04 1970 +0000
654 @@ -0,0 +1,4 @@
691 @@ -0,0 +1,4 @@
655 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
692 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
656 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
693 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
657 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
694 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
658 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
695 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
659 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
696 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
660 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
697 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
661 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
698 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
662 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
699 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
663 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
700 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
664 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
701 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
665 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
702 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
666 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
703 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
667 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
704 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
668 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
705 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
669 +foo
706 +foo
670 +
707 +
671 +bar
708 +bar
672
709
673
710
674
711
675 $ rm mbox
712 $ rm mbox
676
713
677 iso-8859-1 patch:
714 iso-8859-1 patch:
678 $ "$PYTHON" -c 'fp = open("isolatin", "wb"); fp.write(b"h\xF6mma!\n"); fp.close();'
715 $ "$PYTHON" -c 'fp = open("isolatin", "wb"); fp.write(b"h\xF6mma!\n"); fp.close();'
679 $ hg commit -A -d '5 0' -m 'isolatin 8-bit encoding'
716 $ hg commit -A -d '5 0' -m 'isolatin 8-bit encoding'
680 adding isolatin
717 adding isolatin
681
718
682 iso-8859-1 mbox:
719 iso-8859-1 mbox:
683 $ hg email --date '1970-1-1 0:5' -f quux -t foo -c bar -r tip -m mbox
720 $ hg email --date '1970-1-1 0:5' -f quux -t foo -c bar -r tip -m mbox
684 this patch series consists of 1 patches.
721 this patch series consists of 1 patches.
685
722
686
723
687 sending [PATCH] isolatin 8-bit encoding ...
724 sending [PATCH] isolatin 8-bit encoding ...
688 $ cat mbox
725 $ cat mbox
689 From quux ... ... .. ..:..:.. .... (re)
726 From quux ... ... .. ..:..:.. .... (re)
690 MIME-Version: 1.0
727 MIME-Version: 1.0
691 Content-Type: text/plain; charset="iso-8859-1"
728 Content-Type: text/plain; charset="iso-8859-1"
692 Content-Transfer-Encoding: quoted-printable
729 Content-Transfer-Encoding: quoted-printable
693 Subject: [PATCH] isolatin 8-bit encoding
730 Subject: [PATCH] isolatin 8-bit encoding
694 X-Mercurial-Node: 4d6f44f466c96d89f2e7e865a70ff41d8b6eee37
731 X-Mercurial-Node: 4d6f44f466c96d89f2e7e865a70ff41d8b6eee37
695 X-Mercurial-Series-Index: 1
732 X-Mercurial-Series-Index: 1
696 X-Mercurial-Series-Total: 1
733 X-Mercurial-Series-Total: 1
697 Message-Id: <4d6f44f466c96d89f2e7.300@test-hostname>
734 Message-Id: <4d6f44f466c96d89f2e7.300@test-hostname>
698 X-Mercurial-Series-Id: <4d6f44f466c96d89f2e7.300@test-hostname>
735 X-Mercurial-Series-Id: <4d6f44f466c96d89f2e7.300@test-hostname>
699 User-Agent: Mercurial-patchbomb/* (glob)
736 User-Agent: Mercurial-patchbomb/* (glob)
700 Date: Thu, 01 Jan 1970 00:05:00 +0000
737 Date: Thu, 01 Jan 1970 00:05:00 +0000
701 From: quux
738 From: quux
702 To: foo
739 To: foo
703 Cc: bar
740 Cc: bar
704
741
705 # HG changeset patch
742 # HG changeset patch
706 # User test
743 # User test
707 # Date 5 0
744 # Date 5 0
708 # Thu Jan 01 00:00:05 1970 +0000
745 # Thu Jan 01 00:00:05 1970 +0000
709 # Node ID 4d6f44f466c96d89f2e7e865a70ff41d8b6eee37
746 # Node ID 4d6f44f466c96d89f2e7e865a70ff41d8b6eee37
710 # Parent 0c7b871cb86b61a1c07e244393603c361e4a178d
747 # Parent 0c7b871cb86b61a1c07e244393603c361e4a178d
711 isolatin 8-bit encoding
748 isolatin 8-bit encoding
712
749
713 diff -r 0c7b871cb86b -r 4d6f44f466c9 isolatin
750 diff -r 0c7b871cb86b -r 4d6f44f466c9 isolatin
714 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
751 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
715 +++ b/isolatin Thu Jan 01 00:00:05 1970 +0000
752 +++ b/isolatin Thu Jan 01 00:00:05 1970 +0000
716 @@ -0,0 +1,1 @@
753 @@ -0,0 +1,1 @@
717 +h=F6mma!
754 +h=F6mma!
718
755
719
756
720
757
721 test diffstat for single patch:
758 test diffstat for single patch:
722 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -d -y -r 2
759 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -d -y -r 2
723 this patch series consists of 1 patches.
760 this patch series consists of 1 patches.
724
761
725
762
726 Final summary:
763 Final summary:
727
764
728 From: quux
765 From: quux
729 To: foo
766 To: foo
730 Cc: bar
767 Cc: bar
731 Subject: [PATCH] test
768 Subject: [PATCH] test
732 c | 1 +
769 c | 1 +
733 1 files changed, 1 insertions(+), 0 deletions(-)
770 1 files changed, 1 insertions(+), 0 deletions(-)
734
771
735 are you sure you want to send (yn)? y
772 are you sure you want to send (yn)? y
736
773
737 displaying [PATCH] test ...
774 displaying [PATCH] test ...
738 MIME-Version: 1.0
775 MIME-Version: 1.0
739 Content-Type: text/plain; charset="us-ascii"
776 Content-Type: text/plain; charset="us-ascii"
740 Content-Transfer-Encoding: 7bit
777 Content-Transfer-Encoding: 7bit
741 Subject: [PATCH] test
778 Subject: [PATCH] test
742 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
779 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
743 X-Mercurial-Series-Index: 1
780 X-Mercurial-Series-Index: 1
744 X-Mercurial-Series-Total: 1
781 X-Mercurial-Series-Total: 1
745 Message-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
782 Message-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
746 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
783 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
747 User-Agent: Mercurial-patchbomb/* (glob)
784 User-Agent: Mercurial-patchbomb/* (glob)
748 Date: Thu, 01 Jan 1970 00:01:00 +0000
785 Date: Thu, 01 Jan 1970 00:01:00 +0000
749 From: quux
786 From: quux
750 To: foo
787 To: foo
751 Cc: bar
788 Cc: bar
752
789
753 c | 1 +
790 c | 1 +
754 1 files changed, 1 insertions(+), 0 deletions(-)
791 1 files changed, 1 insertions(+), 0 deletions(-)
755
792
756
793
757 # HG changeset patch
794 # HG changeset patch
758 # User test
795 # User test
759 # Date 3 0
796 # Date 3 0
760 # Thu Jan 01 00:00:03 1970 +0000
797 # Thu Jan 01 00:00:03 1970 +0000
761 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
798 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
762 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
799 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
763 c
800 c
764
801
765 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
802 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
766 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
803 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
767 +++ b/c Thu Jan 01 00:00:03 1970 +0000
804 +++ b/c Thu Jan 01 00:00:03 1970 +0000
768 @@ -0,0 +1,1 @@
805 @@ -0,0 +1,1 @@
769 +c
806 +c
770
807
771
808
772 test diffstat for multiple patches:
809 test diffstat for multiple patches:
773 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -d -y \
810 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -d -y \
774 > -r 0:1
811 > -r 0:1
775 this patch series consists of 2 patches.
812 this patch series consists of 2 patches.
776
813
777
814
778 Write the introductory message for the patch series.
815 Write the introductory message for the patch series.
779
816
780
817
781 Final summary:
818 Final summary:
782
819
783 From: quux
820 From: quux
784 To: foo
821 To: foo
785 Cc: bar
822 Cc: bar
786 Subject: [PATCH 0 of 2] test
823 Subject: [PATCH 0 of 2] test
787 a | 1 +
824 a | 1 +
788 b | 1 +
825 b | 1 +
789 2 files changed, 2 insertions(+), 0 deletions(-)
826 2 files changed, 2 insertions(+), 0 deletions(-)
790 Subject: [PATCH 1 of 2] a
827 Subject: [PATCH 1 of 2] a
791 a | 1 +
828 a | 1 +
792 1 files changed, 1 insertions(+), 0 deletions(-)
829 1 files changed, 1 insertions(+), 0 deletions(-)
793 Subject: [PATCH 2 of 2] b
830 Subject: [PATCH 2 of 2] b
794 b | 1 +
831 b | 1 +
795 1 files changed, 1 insertions(+), 0 deletions(-)
832 1 files changed, 1 insertions(+), 0 deletions(-)
796
833
797 are you sure you want to send (yn)? y
834 are you sure you want to send (yn)? y
798
835
799 displaying [PATCH 0 of 2] test ...
836 displaying [PATCH 0 of 2] test ...
800 MIME-Version: 1.0
837 MIME-Version: 1.0
801 Content-Type: text/plain; charset="us-ascii"
838 Content-Type: text/plain; charset="us-ascii"
802 Content-Transfer-Encoding: 7bit
839 Content-Transfer-Encoding: 7bit
803 Subject: [PATCH 0 of 2] test
840 Subject: [PATCH 0 of 2] test
804 Message-Id: <patchbomb.60@test-hostname>
841 Message-Id: <patchbomb.60@test-hostname>
805 User-Agent: Mercurial-patchbomb/* (glob)
842 User-Agent: Mercurial-patchbomb/* (glob)
806 Date: Thu, 01 Jan 1970 00:01:00 +0000
843 Date: Thu, 01 Jan 1970 00:01:00 +0000
807 From: quux
844 From: quux
808 To: foo
845 To: foo
809 Cc: bar
846 Cc: bar
810
847
811
848
812 a | 1 +
849 a | 1 +
813 b | 1 +
850 b | 1 +
814 2 files changed, 2 insertions(+), 0 deletions(-)
851 2 files changed, 2 insertions(+), 0 deletions(-)
815
852
816 displaying [PATCH 1 of 2] a ...
853 displaying [PATCH 1 of 2] a ...
817 MIME-Version: 1.0
854 MIME-Version: 1.0
818 Content-Type: text/plain; charset="us-ascii"
855 Content-Type: text/plain; charset="us-ascii"
819 Content-Transfer-Encoding: 7bit
856 Content-Transfer-Encoding: 7bit
820 Subject: [PATCH 1 of 2] a
857 Subject: [PATCH 1 of 2] a
821 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
858 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
822 X-Mercurial-Series-Index: 1
859 X-Mercurial-Series-Index: 1
823 X-Mercurial-Series-Total: 2
860 X-Mercurial-Series-Total: 2
824 Message-Id: <8580ff50825a50c8f716.61@test-hostname>
861 Message-Id: <8580ff50825a50c8f716.61@test-hostname>
825 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
862 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
826 In-Reply-To: <patchbomb.60@test-hostname>
863 In-Reply-To: <patchbomb.60@test-hostname>
827 References: <patchbomb.60@test-hostname>
864 References: <patchbomb.60@test-hostname>
828 User-Agent: Mercurial-patchbomb/* (glob)
865 User-Agent: Mercurial-patchbomb/* (glob)
829 Date: Thu, 01 Jan 1970 00:01:01 +0000
866 Date: Thu, 01 Jan 1970 00:01:01 +0000
830 From: quux
867 From: quux
831 To: foo
868 To: foo
832 Cc: bar
869 Cc: bar
833
870
834 a | 1 +
871 a | 1 +
835 1 files changed, 1 insertions(+), 0 deletions(-)
872 1 files changed, 1 insertions(+), 0 deletions(-)
836
873
837
874
838 # HG changeset patch
875 # HG changeset patch
839 # User test
876 # User test
840 # Date 1 0
877 # Date 1 0
841 # Thu Jan 01 00:00:01 1970 +0000
878 # Thu Jan 01 00:00:01 1970 +0000
842 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
879 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
843 # Parent 0000000000000000000000000000000000000000
880 # Parent 0000000000000000000000000000000000000000
844 a
881 a
845
882
846 diff -r 000000000000 -r 8580ff50825a a
883 diff -r 000000000000 -r 8580ff50825a a
847 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
884 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
848 +++ b/a Thu Jan 01 00:00:01 1970 +0000
885 +++ b/a Thu Jan 01 00:00:01 1970 +0000
849 @@ -0,0 +1,1 @@
886 @@ -0,0 +1,1 @@
850 +a
887 +a
851
888
852 displaying [PATCH 2 of 2] b ...
889 displaying [PATCH 2 of 2] b ...
853 MIME-Version: 1.0
890 MIME-Version: 1.0
854 Content-Type: text/plain; charset="us-ascii"
891 Content-Type: text/plain; charset="us-ascii"
855 Content-Transfer-Encoding: 7bit
892 Content-Transfer-Encoding: 7bit
856 Subject: [PATCH 2 of 2] b
893 Subject: [PATCH 2 of 2] b
857 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
894 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
858 X-Mercurial-Series-Index: 2
895 X-Mercurial-Series-Index: 2
859 X-Mercurial-Series-Total: 2
896 X-Mercurial-Series-Total: 2
860 Message-Id: <97d72e5f12c7e84f8506.62@test-hostname>
897 Message-Id: <97d72e5f12c7e84f8506.62@test-hostname>
861 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
898 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
862 In-Reply-To: <patchbomb.60@test-hostname>
899 In-Reply-To: <patchbomb.60@test-hostname>
863 References: <patchbomb.60@test-hostname>
900 References: <patchbomb.60@test-hostname>
864 User-Agent: Mercurial-patchbomb/* (glob)
901 User-Agent: Mercurial-patchbomb/* (glob)
865 Date: Thu, 01 Jan 1970 00:01:02 +0000
902 Date: Thu, 01 Jan 1970 00:01:02 +0000
866 From: quux
903 From: quux
867 To: foo
904 To: foo
868 Cc: bar
905 Cc: bar
869
906
870 b | 1 +
907 b | 1 +
871 1 files changed, 1 insertions(+), 0 deletions(-)
908 1 files changed, 1 insertions(+), 0 deletions(-)
872
909
873
910
874 # HG changeset patch
911 # HG changeset patch
875 # User test
912 # User test
876 # Date 2 0
913 # Date 2 0
877 # Thu Jan 01 00:00:02 1970 +0000
914 # Thu Jan 01 00:00:02 1970 +0000
878 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
915 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
879 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
916 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
880 b
917 b
881
918
882 diff -r 8580ff50825a -r 97d72e5f12c7 b
919 diff -r 8580ff50825a -r 97d72e5f12c7 b
883 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
920 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
884 +++ b/b Thu Jan 01 00:00:02 1970 +0000
921 +++ b/b Thu Jan 01 00:00:02 1970 +0000
885 @@ -0,0 +1,1 @@
922 @@ -0,0 +1,1 @@
886 +b
923 +b
887
924
888
925
889 test inline for single patch:
926 test inline for single patch:
890 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -i -r 2 | filterboundary
927 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -i -r 2 | filterboundary
891 this patch series consists of 1 patches.
928 this patch series consists of 1 patches.
892
929
893
930
894 displaying [PATCH] test ...
931 displaying [PATCH] test ...
895 Content-Type: multipart/mixed; boundary="===*==" (glob)
932 Content-Type: multipart/mixed; boundary="===*==" (glob)
896 MIME-Version: 1.0
933 MIME-Version: 1.0
897 Subject: [PATCH] test
934 Subject: [PATCH] test
898 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
935 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
899 X-Mercurial-Series-Index: 1
936 X-Mercurial-Series-Index: 1
900 X-Mercurial-Series-Total: 1
937 X-Mercurial-Series-Total: 1
901 Message-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
938 Message-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
902 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
939 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
903 User-Agent: Mercurial-patchbomb/* (glob)
940 User-Agent: Mercurial-patchbomb/* (glob)
904 Date: Thu, 01 Jan 1970 00:01:00 +0000
941 Date: Thu, 01 Jan 1970 00:01:00 +0000
905 From: quux
942 From: quux
906 To: foo
943 To: foo
907 Cc: bar
944 Cc: bar
908
945
909 --===*= (glob)
946 --===*= (glob)
910 MIME-Version: 1.0
947 MIME-Version: 1.0
911 Content-Type: text/x-patch; charset="us-ascii"
948 Content-Type: text/x-patch; charset="us-ascii"
912 Content-Transfer-Encoding: 7bit
949 Content-Transfer-Encoding: 7bit
913 Content-Disposition: inline; filename=t2.patch
950 Content-Disposition: inline; filename=t2.patch
914
951
915 # HG changeset patch
952 # HG changeset patch
916 # User test
953 # User test
917 # Date 3 0
954 # Date 3 0
918 # Thu Jan 01 00:00:03 1970 +0000
955 # Thu Jan 01 00:00:03 1970 +0000
919 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
956 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
920 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
957 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
921 c
958 c
922
959
923 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
960 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
924 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
961 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
925 +++ b/c Thu Jan 01 00:00:03 1970 +0000
962 +++ b/c Thu Jan 01 00:00:03 1970 +0000
926 @@ -0,0 +1,1 @@
963 @@ -0,0 +1,1 @@
927 +c
964 +c
928
965
929 --===*=-- (glob)
966 --===*=-- (glob)
930
967
931
968
932 test inline for single patch (quoted-printable):
969 test inline for single patch (quoted-printable):
933 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -i -r 4 | filterboundary
970 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -i -r 4 | filterboundary
934 this patch series consists of 1 patches.
971 this patch series consists of 1 patches.
935
972
936
973
937 displaying [PATCH] test ...
974 displaying [PATCH] test ...
938 Content-Type: multipart/mixed; boundary="===*==" (glob)
975 Content-Type: multipart/mixed; boundary="===*==" (glob)
939 MIME-Version: 1.0
976 MIME-Version: 1.0
940 Subject: [PATCH] test
977 Subject: [PATCH] test
941 X-Mercurial-Node: 0c7b871cb86b61a1c07e244393603c361e4a178d
978 X-Mercurial-Node: 0c7b871cb86b61a1c07e244393603c361e4a178d
942 X-Mercurial-Series-Index: 1
979 X-Mercurial-Series-Index: 1
943 X-Mercurial-Series-Total: 1
980 X-Mercurial-Series-Total: 1
944 Message-Id: <0c7b871cb86b61a1c07e.60@test-hostname>
981 Message-Id: <0c7b871cb86b61a1c07e.60@test-hostname>
945 X-Mercurial-Series-Id: <0c7b871cb86b61a1c07e.60@test-hostname>
982 X-Mercurial-Series-Id: <0c7b871cb86b61a1c07e.60@test-hostname>
946 User-Agent: Mercurial-patchbomb/* (glob)
983 User-Agent: Mercurial-patchbomb/* (glob)
947 Date: Thu, 01 Jan 1970 00:01:00 +0000
984 Date: Thu, 01 Jan 1970 00:01:00 +0000
948 From: quux
985 From: quux
949 To: foo
986 To: foo
950 Cc: bar
987 Cc: bar
951
988
952 --===*= (glob)
989 --===*= (glob)
953 MIME-Version: 1.0
990 MIME-Version: 1.0
954 Content-Type: text/x-patch; charset="us-ascii"
991 Content-Type: text/x-patch; charset="us-ascii"
955 Content-Transfer-Encoding: quoted-printable
992 Content-Transfer-Encoding: quoted-printable
956 Content-Disposition: inline; filename=t2.patch
993 Content-Disposition: inline; filename=t2.patch
957
994
958 # HG changeset patch
995 # HG changeset patch
959 # User test
996 # User test
960 # Date 4 0
997 # Date 4 0
961 # Thu Jan 01 00:00:04 1970 +0000
998 # Thu Jan 01 00:00:04 1970 +0000
962 # Node ID 0c7b871cb86b61a1c07e244393603c361e4a178d
999 # Node ID 0c7b871cb86b61a1c07e244393603c361e4a178d
963 # Parent f81ef97829467e868fc405fccbcfa66217e4d3e6
1000 # Parent f81ef97829467e868fc405fccbcfa66217e4d3e6
964 long line
1001 long line
965
1002
966 diff -r f81ef9782946 -r 0c7b871cb86b long
1003 diff -r f81ef9782946 -r 0c7b871cb86b long
967 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1004 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
968 +++ b/long Thu Jan 01 00:00:04 1970 +0000
1005 +++ b/long Thu Jan 01 00:00:04 1970 +0000
969 @@ -0,0 +1,4 @@
1006 @@ -0,0 +1,4 @@
970 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1007 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
971 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1008 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
972 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1009 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
973 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1010 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
974 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1011 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
975 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1012 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
976 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1013 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
977 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1014 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
978 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1015 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
979 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1016 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
980 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1017 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
981 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1018 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
982 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1019 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
983 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
1020 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
984 +foo
1021 +foo
985 +
1022 +
986 +bar
1023 +bar
987
1024
988 --===*=-- (glob)
1025 --===*=-- (glob)
989
1026
990 test inline for multiple patches:
1027 test inline for multiple patches:
991 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -i \
1028 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -i \
992 > -r 0:1 -r 4 | filterboundary
1029 > -r 0:1 -r 4 | filterboundary
993 this patch series consists of 3 patches.
1030 this patch series consists of 3 patches.
994
1031
995
1032
996 Write the introductory message for the patch series.
1033 Write the introductory message for the patch series.
997
1034
998
1035
999 displaying [PATCH 0 of 3] test ...
1036 displaying [PATCH 0 of 3] test ...
1000 MIME-Version: 1.0
1037 MIME-Version: 1.0
1001 Content-Type: text/plain; charset="us-ascii"
1038 Content-Type: text/plain; charset="us-ascii"
1002 Content-Transfer-Encoding: 7bit
1039 Content-Transfer-Encoding: 7bit
1003 Subject: [PATCH 0 of 3] test
1040 Subject: [PATCH 0 of 3] test
1004 Message-Id: <patchbomb.60@test-hostname>
1041 Message-Id: <patchbomb.60@test-hostname>
1005 User-Agent: Mercurial-patchbomb/* (glob)
1042 User-Agent: Mercurial-patchbomb/* (glob)
1006 Date: Thu, 01 Jan 1970 00:01:00 +0000
1043 Date: Thu, 01 Jan 1970 00:01:00 +0000
1007 From: quux
1044 From: quux
1008 To: foo
1045 To: foo
1009 Cc: bar
1046 Cc: bar
1010
1047
1011
1048
1012 displaying [PATCH 1 of 3] a ...
1049 displaying [PATCH 1 of 3] a ...
1013 Content-Type: multipart/mixed; boundary="===*==" (glob)
1050 Content-Type: multipart/mixed; boundary="===*==" (glob)
1014 MIME-Version: 1.0
1051 MIME-Version: 1.0
1015 Subject: [PATCH 1 of 3] a
1052 Subject: [PATCH 1 of 3] a
1016 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
1053 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
1017 X-Mercurial-Series-Index: 1
1054 X-Mercurial-Series-Index: 1
1018 X-Mercurial-Series-Total: 3
1055 X-Mercurial-Series-Total: 3
1019 Message-Id: <8580ff50825a50c8f716.61@test-hostname>
1056 Message-Id: <8580ff50825a50c8f716.61@test-hostname>
1020 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
1057 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
1021 In-Reply-To: <patchbomb.60@test-hostname>
1058 In-Reply-To: <patchbomb.60@test-hostname>
1022 References: <patchbomb.60@test-hostname>
1059 References: <patchbomb.60@test-hostname>
1023 User-Agent: Mercurial-patchbomb/* (glob)
1060 User-Agent: Mercurial-patchbomb/* (glob)
1024 Date: Thu, 01 Jan 1970 00:01:01 +0000
1061 Date: Thu, 01 Jan 1970 00:01:01 +0000
1025 From: quux
1062 From: quux
1026 To: foo
1063 To: foo
1027 Cc: bar
1064 Cc: bar
1028
1065
1029 --===*= (glob)
1066 --===*= (glob)
1030 MIME-Version: 1.0
1067 MIME-Version: 1.0
1031 Content-Type: text/x-patch; charset="us-ascii"
1068 Content-Type: text/x-patch; charset="us-ascii"
1032 Content-Transfer-Encoding: 7bit
1069 Content-Transfer-Encoding: 7bit
1033 Content-Disposition: inline; filename=t2-1.patch
1070 Content-Disposition: inline; filename=t2-1.patch
1034
1071
1035 # HG changeset patch
1072 # HG changeset patch
1036 # User test
1073 # User test
1037 # Date 1 0
1074 # Date 1 0
1038 # Thu Jan 01 00:00:01 1970 +0000
1075 # Thu Jan 01 00:00:01 1970 +0000
1039 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
1076 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
1040 # Parent 0000000000000000000000000000000000000000
1077 # Parent 0000000000000000000000000000000000000000
1041 a
1078 a
1042
1079
1043 diff -r 000000000000 -r 8580ff50825a a
1080 diff -r 000000000000 -r 8580ff50825a a
1044 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1081 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1045 +++ b/a Thu Jan 01 00:00:01 1970 +0000
1082 +++ b/a Thu Jan 01 00:00:01 1970 +0000
1046 @@ -0,0 +1,1 @@
1083 @@ -0,0 +1,1 @@
1047 +a
1084 +a
1048
1085
1049 --===*=-- (glob)
1086 --===*=-- (glob)
1050 displaying [PATCH 2 of 3] b ...
1087 displaying [PATCH 2 of 3] b ...
1051 Content-Type: multipart/mixed; boundary="===*==" (glob)
1088 Content-Type: multipart/mixed; boundary="===*==" (glob)
1052 MIME-Version: 1.0
1089 MIME-Version: 1.0
1053 Subject: [PATCH 2 of 3] b
1090 Subject: [PATCH 2 of 3] b
1054 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1091 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1055 X-Mercurial-Series-Index: 2
1092 X-Mercurial-Series-Index: 2
1056 X-Mercurial-Series-Total: 3
1093 X-Mercurial-Series-Total: 3
1057 Message-Id: <97d72e5f12c7e84f8506.62@test-hostname>
1094 Message-Id: <97d72e5f12c7e84f8506.62@test-hostname>
1058 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
1095 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
1059 In-Reply-To: <patchbomb.60@test-hostname>
1096 In-Reply-To: <patchbomb.60@test-hostname>
1060 References: <patchbomb.60@test-hostname>
1097 References: <patchbomb.60@test-hostname>
1061 User-Agent: Mercurial-patchbomb/* (glob)
1098 User-Agent: Mercurial-patchbomb/* (glob)
1062 Date: Thu, 01 Jan 1970 00:01:02 +0000
1099 Date: Thu, 01 Jan 1970 00:01:02 +0000
1063 From: quux
1100 From: quux
1064 To: foo
1101 To: foo
1065 Cc: bar
1102 Cc: bar
1066
1103
1067 --===*= (glob)
1104 --===*= (glob)
1068 MIME-Version: 1.0
1105 MIME-Version: 1.0
1069 Content-Type: text/x-patch; charset="us-ascii"
1106 Content-Type: text/x-patch; charset="us-ascii"
1070 Content-Transfer-Encoding: 7bit
1107 Content-Transfer-Encoding: 7bit
1071 Content-Disposition: inline; filename=t2-2.patch
1108 Content-Disposition: inline; filename=t2-2.patch
1072
1109
1073 # HG changeset patch
1110 # HG changeset patch
1074 # User test
1111 # User test
1075 # Date 2 0
1112 # Date 2 0
1076 # Thu Jan 01 00:00:02 1970 +0000
1113 # Thu Jan 01 00:00:02 1970 +0000
1077 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1114 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1078 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
1115 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
1079 b
1116 b
1080
1117
1081 diff -r 8580ff50825a -r 97d72e5f12c7 b
1118 diff -r 8580ff50825a -r 97d72e5f12c7 b
1082 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1119 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1083 +++ b/b Thu Jan 01 00:00:02 1970 +0000
1120 +++ b/b Thu Jan 01 00:00:02 1970 +0000
1084 @@ -0,0 +1,1 @@
1121 @@ -0,0 +1,1 @@
1085 +b
1122 +b
1086
1123
1087 --===*=-- (glob)
1124 --===*=-- (glob)
1088 displaying [PATCH 3 of 3] long line ...
1125 displaying [PATCH 3 of 3] long line ...
1089 Content-Type: multipart/mixed; boundary="===*==" (glob)
1126 Content-Type: multipart/mixed; boundary="===*==" (glob)
1090 MIME-Version: 1.0
1127 MIME-Version: 1.0
1091 Subject: [PATCH 3 of 3] long line
1128 Subject: [PATCH 3 of 3] long line
1092 X-Mercurial-Node: 0c7b871cb86b61a1c07e244393603c361e4a178d
1129 X-Mercurial-Node: 0c7b871cb86b61a1c07e244393603c361e4a178d
1093 X-Mercurial-Series-Index: 3
1130 X-Mercurial-Series-Index: 3
1094 X-Mercurial-Series-Total: 3
1131 X-Mercurial-Series-Total: 3
1095 Message-Id: <0c7b871cb86b61a1c07e.63@test-hostname>
1132 Message-Id: <0c7b871cb86b61a1c07e.63@test-hostname>
1096 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
1133 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
1097 In-Reply-To: <patchbomb.60@test-hostname>
1134 In-Reply-To: <patchbomb.60@test-hostname>
1098 References: <patchbomb.60@test-hostname>
1135 References: <patchbomb.60@test-hostname>
1099 User-Agent: Mercurial-patchbomb/* (glob)
1136 User-Agent: Mercurial-patchbomb/* (glob)
1100 Date: Thu, 01 Jan 1970 00:01:03 +0000
1137 Date: Thu, 01 Jan 1970 00:01:03 +0000
1101 From: quux
1138 From: quux
1102 To: foo
1139 To: foo
1103 Cc: bar
1140 Cc: bar
1104
1141
1105 --===*= (glob)
1142 --===*= (glob)
1106 MIME-Version: 1.0
1143 MIME-Version: 1.0
1107 Content-Type: text/x-patch; charset="us-ascii"
1144 Content-Type: text/x-patch; charset="us-ascii"
1108 Content-Transfer-Encoding: quoted-printable
1145 Content-Transfer-Encoding: quoted-printable
1109 Content-Disposition: inline; filename=t2-3.patch
1146 Content-Disposition: inline; filename=t2-3.patch
1110
1147
1111 # HG changeset patch
1148 # HG changeset patch
1112 # User test
1149 # User test
1113 # Date 4 0
1150 # Date 4 0
1114 # Thu Jan 01 00:00:04 1970 +0000
1151 # Thu Jan 01 00:00:04 1970 +0000
1115 # Node ID 0c7b871cb86b61a1c07e244393603c361e4a178d
1152 # Node ID 0c7b871cb86b61a1c07e244393603c361e4a178d
1116 # Parent f81ef97829467e868fc405fccbcfa66217e4d3e6
1153 # Parent f81ef97829467e868fc405fccbcfa66217e4d3e6
1117 long line
1154 long line
1118
1155
1119 diff -r f81ef9782946 -r 0c7b871cb86b long
1156 diff -r f81ef9782946 -r 0c7b871cb86b long
1120 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1157 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1121 +++ b/long Thu Jan 01 00:00:04 1970 +0000
1158 +++ b/long Thu Jan 01 00:00:04 1970 +0000
1122 @@ -0,0 +1,4 @@
1159 @@ -0,0 +1,4 @@
1123 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1160 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1124 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1161 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1125 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1162 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1126 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1163 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1127 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1164 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1128 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1165 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1129 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1166 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1130 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1167 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1131 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1168 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1132 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1169 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1133 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1170 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1134 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1171 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1135 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1172 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1136 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
1173 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
1137 +foo
1174 +foo
1138 +
1175 +
1139 +bar
1176 +bar
1140
1177
1141 --===*=-- (glob)
1178 --===*=-- (glob)
1142
1179
1143 test attach for single patch:
1180 test attach for single patch:
1144 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -a -r 2 | filterboundary
1181 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -a -r 2 | filterboundary
1145 this patch series consists of 1 patches.
1182 this patch series consists of 1 patches.
1146
1183
1147
1184
1148 displaying [PATCH] test ...
1185 displaying [PATCH] test ...
1149 Content-Type: multipart/mixed; boundary="===*==" (glob)
1186 Content-Type: multipart/mixed; boundary="===*==" (glob)
1150 MIME-Version: 1.0
1187 MIME-Version: 1.0
1151 Subject: [PATCH] test
1188 Subject: [PATCH] test
1152 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1189 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1153 X-Mercurial-Series-Index: 1
1190 X-Mercurial-Series-Index: 1
1154 X-Mercurial-Series-Total: 1
1191 X-Mercurial-Series-Total: 1
1155 Message-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
1192 Message-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
1156 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
1193 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
1157 User-Agent: Mercurial-patchbomb/* (glob)
1194 User-Agent: Mercurial-patchbomb/* (glob)
1158 Date: Thu, 01 Jan 1970 00:01:00 +0000
1195 Date: Thu, 01 Jan 1970 00:01:00 +0000
1159 From: quux
1196 From: quux
1160 To: foo
1197 To: foo
1161 Cc: bar
1198 Cc: bar
1162
1199
1163 --===*= (glob)
1200 --===*= (glob)
1164 MIME-Version: 1.0
1201 MIME-Version: 1.0
1165 Content-Type: text/plain; charset="us-ascii"
1202 Content-Type: text/plain; charset="us-ascii"
1166 Content-Transfer-Encoding: 7bit
1203 Content-Transfer-Encoding: 7bit
1167
1204
1168 Patch subject is complete summary.
1205 Patch subject is complete summary.
1169
1206
1170
1207
1171
1208
1172 --===*= (glob)
1209 --===*= (glob)
1173 MIME-Version: 1.0
1210 MIME-Version: 1.0
1174 Content-Type: text/x-patch; charset="us-ascii"
1211 Content-Type: text/x-patch; charset="us-ascii"
1175 Content-Transfer-Encoding: 7bit
1212 Content-Transfer-Encoding: 7bit
1176 Content-Disposition: attachment; filename=t2.patch
1213 Content-Disposition: attachment; filename=t2.patch
1177
1214
1178 # HG changeset patch
1215 # HG changeset patch
1179 # User test
1216 # User test
1180 # Date 3 0
1217 # Date 3 0
1181 # Thu Jan 01 00:00:03 1970 +0000
1218 # Thu Jan 01 00:00:03 1970 +0000
1182 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1219 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1183 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1220 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1184 c
1221 c
1185
1222
1186 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1223 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1187 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1224 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1188 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1225 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1189 @@ -0,0 +1,1 @@
1226 @@ -0,0 +1,1 @@
1190 +c
1227 +c
1191
1228
1192 --===*=-- (glob)
1229 --===*=-- (glob)
1193
1230
1194 test attach for single patch (quoted-printable):
1231 test attach for single patch (quoted-printable):
1195 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -a -r 4 | filterboundary
1232 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -a -r 4 | filterboundary
1196 this patch series consists of 1 patches.
1233 this patch series consists of 1 patches.
1197
1234
1198
1235
1199 displaying [PATCH] test ...
1236 displaying [PATCH] test ...
1200 Content-Type: multipart/mixed; boundary="===*==" (glob)
1237 Content-Type: multipart/mixed; boundary="===*==" (glob)
1201 MIME-Version: 1.0
1238 MIME-Version: 1.0
1202 Subject: [PATCH] test
1239 Subject: [PATCH] test
1203 X-Mercurial-Node: 0c7b871cb86b61a1c07e244393603c361e4a178d
1240 X-Mercurial-Node: 0c7b871cb86b61a1c07e244393603c361e4a178d
1204 X-Mercurial-Series-Index: 1
1241 X-Mercurial-Series-Index: 1
1205 X-Mercurial-Series-Total: 1
1242 X-Mercurial-Series-Total: 1
1206 Message-Id: <0c7b871cb86b61a1c07e.60@test-hostname>
1243 Message-Id: <0c7b871cb86b61a1c07e.60@test-hostname>
1207 X-Mercurial-Series-Id: <0c7b871cb86b61a1c07e.60@test-hostname>
1244 X-Mercurial-Series-Id: <0c7b871cb86b61a1c07e.60@test-hostname>
1208 User-Agent: Mercurial-patchbomb/* (glob)
1245 User-Agent: Mercurial-patchbomb/* (glob)
1209 Date: Thu, 01 Jan 1970 00:01:00 +0000
1246 Date: Thu, 01 Jan 1970 00:01:00 +0000
1210 From: quux
1247 From: quux
1211 To: foo
1248 To: foo
1212 Cc: bar
1249 Cc: bar
1213
1250
1214 --===*= (glob)
1251 --===*= (glob)
1215 MIME-Version: 1.0
1252 MIME-Version: 1.0
1216 Content-Type: text/plain; charset="us-ascii"
1253 Content-Type: text/plain; charset="us-ascii"
1217 Content-Transfer-Encoding: 7bit
1254 Content-Transfer-Encoding: 7bit
1218
1255
1219 Patch subject is complete summary.
1256 Patch subject is complete summary.
1220
1257
1221
1258
1222
1259
1223 --===*= (glob)
1260 --===*= (glob)
1224 MIME-Version: 1.0
1261 MIME-Version: 1.0
1225 Content-Type: text/x-patch; charset="us-ascii"
1262 Content-Type: text/x-patch; charset="us-ascii"
1226 Content-Transfer-Encoding: quoted-printable
1263 Content-Transfer-Encoding: quoted-printable
1227 Content-Disposition: attachment; filename=t2.patch
1264 Content-Disposition: attachment; filename=t2.patch
1228
1265
1229 # HG changeset patch
1266 # HG changeset patch
1230 # User test
1267 # User test
1231 # Date 4 0
1268 # Date 4 0
1232 # Thu Jan 01 00:00:04 1970 +0000
1269 # Thu Jan 01 00:00:04 1970 +0000
1233 # Node ID 0c7b871cb86b61a1c07e244393603c361e4a178d
1270 # Node ID 0c7b871cb86b61a1c07e244393603c361e4a178d
1234 # Parent f81ef97829467e868fc405fccbcfa66217e4d3e6
1271 # Parent f81ef97829467e868fc405fccbcfa66217e4d3e6
1235 long line
1272 long line
1236
1273
1237 diff -r f81ef9782946 -r 0c7b871cb86b long
1274 diff -r f81ef9782946 -r 0c7b871cb86b long
1238 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1275 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1239 +++ b/long Thu Jan 01 00:00:04 1970 +0000
1276 +++ b/long Thu Jan 01 00:00:04 1970 +0000
1240 @@ -0,0 +1,4 @@
1277 @@ -0,0 +1,4 @@
1241 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1278 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1242 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1279 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1243 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1280 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1244 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1281 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1245 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1282 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1246 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1283 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1247 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1284 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1248 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1285 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1249 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1286 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1250 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1287 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1251 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1288 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1252 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1289 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1253 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1290 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1254 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
1291 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
1255 +foo
1292 +foo
1256 +
1293 +
1257 +bar
1294 +bar
1258
1295
1259 --===*=-- (glob)
1296 --===*=-- (glob)
1260
1297
1261 test attach and body for single patch:
1298 test attach and body for single patch:
1262 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -a --body -r 2 | filterboundary
1299 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -a --body -r 2 | filterboundary
1263 this patch series consists of 1 patches.
1300 this patch series consists of 1 patches.
1264
1301
1265
1302
1266 displaying [PATCH] test ...
1303 displaying [PATCH] test ...
1267 Content-Type: multipart/mixed; boundary="===*==" (glob)
1304 Content-Type: multipart/mixed; boundary="===*==" (glob)
1268 MIME-Version: 1.0
1305 MIME-Version: 1.0
1269 Subject: [PATCH] test
1306 Subject: [PATCH] test
1270 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1307 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1271 X-Mercurial-Series-Index: 1
1308 X-Mercurial-Series-Index: 1
1272 X-Mercurial-Series-Total: 1
1309 X-Mercurial-Series-Total: 1
1273 Message-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
1310 Message-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
1274 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
1311 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
1275 User-Agent: Mercurial-patchbomb/* (glob)
1312 User-Agent: Mercurial-patchbomb/* (glob)
1276 Date: Thu, 01 Jan 1970 00:01:00 +0000
1313 Date: Thu, 01 Jan 1970 00:01:00 +0000
1277 From: quux
1314 From: quux
1278 To: foo
1315 To: foo
1279 Cc: bar
1316 Cc: bar
1280
1317
1281 --===*= (glob)
1318 --===*= (glob)
1282 MIME-Version: 1.0
1319 MIME-Version: 1.0
1283 Content-Type: text/plain; charset="us-ascii"
1320 Content-Type: text/plain; charset="us-ascii"
1284 Content-Transfer-Encoding: 7bit
1321 Content-Transfer-Encoding: 7bit
1285
1322
1286 # HG changeset patch
1323 # HG changeset patch
1287 # User test
1324 # User test
1288 # Date 3 0
1325 # Date 3 0
1289 # Thu Jan 01 00:00:03 1970 +0000
1326 # Thu Jan 01 00:00:03 1970 +0000
1290 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1327 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1291 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1328 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1292 c
1329 c
1293
1330
1294 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1331 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1295 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1332 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1296 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1333 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1297 @@ -0,0 +1,1 @@
1334 @@ -0,0 +1,1 @@
1298 +c
1335 +c
1299
1336
1300 --===*= (glob)
1337 --===*= (glob)
1301 MIME-Version: 1.0
1338 MIME-Version: 1.0
1302 Content-Type: text/x-patch; charset="us-ascii"
1339 Content-Type: text/x-patch; charset="us-ascii"
1303 Content-Transfer-Encoding: 7bit
1340 Content-Transfer-Encoding: 7bit
1304 Content-Disposition: attachment; filename=t2.patch
1341 Content-Disposition: attachment; filename=t2.patch
1305
1342
1306 # HG changeset patch
1343 # HG changeset patch
1307 # User test
1344 # User test
1308 # Date 3 0
1345 # Date 3 0
1309 # Thu Jan 01 00:00:03 1970 +0000
1346 # Thu Jan 01 00:00:03 1970 +0000
1310 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1347 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1311 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1348 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1312 c
1349 c
1313
1350
1314 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1351 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1315 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1352 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1316 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1353 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1317 @@ -0,0 +1,1 @@
1354 @@ -0,0 +1,1 @@
1318 +c
1355 +c
1319
1356
1320 --===*=-- (glob)
1357 --===*=-- (glob)
1321
1358
1322 test attach for multiple patches:
1359 test attach for multiple patches:
1323 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -a \
1360 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -a \
1324 > -r 0:1 -r 4 | filterboundary
1361 > -r 0:1 -r 4 | filterboundary
1325 this patch series consists of 3 patches.
1362 this patch series consists of 3 patches.
1326
1363
1327
1364
1328 Write the introductory message for the patch series.
1365 Write the introductory message for the patch series.
1329
1366
1330
1367
1331 displaying [PATCH 0 of 3] test ...
1368 displaying [PATCH 0 of 3] test ...
1332 MIME-Version: 1.0
1369 MIME-Version: 1.0
1333 Content-Type: text/plain; charset="us-ascii"
1370 Content-Type: text/plain; charset="us-ascii"
1334 Content-Transfer-Encoding: 7bit
1371 Content-Transfer-Encoding: 7bit
1335 Subject: [PATCH 0 of 3] test
1372 Subject: [PATCH 0 of 3] test
1336 Message-Id: <patchbomb.60@test-hostname>
1373 Message-Id: <patchbomb.60@test-hostname>
1337 User-Agent: Mercurial-patchbomb/* (glob)
1374 User-Agent: Mercurial-patchbomb/* (glob)
1338 Date: Thu, 01 Jan 1970 00:01:00 +0000
1375 Date: Thu, 01 Jan 1970 00:01:00 +0000
1339 From: quux
1376 From: quux
1340 To: foo
1377 To: foo
1341 Cc: bar
1378 Cc: bar
1342
1379
1343
1380
1344 displaying [PATCH 1 of 3] a ...
1381 displaying [PATCH 1 of 3] a ...
1345 Content-Type: multipart/mixed; boundary="===*==" (glob)
1382 Content-Type: multipart/mixed; boundary="===*==" (glob)
1346 MIME-Version: 1.0
1383 MIME-Version: 1.0
1347 Subject: [PATCH 1 of 3] a
1384 Subject: [PATCH 1 of 3] a
1348 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
1385 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
1349 X-Mercurial-Series-Index: 1
1386 X-Mercurial-Series-Index: 1
1350 X-Mercurial-Series-Total: 3
1387 X-Mercurial-Series-Total: 3
1351 Message-Id: <8580ff50825a50c8f716.61@test-hostname>
1388 Message-Id: <8580ff50825a50c8f716.61@test-hostname>
1352 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
1389 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
1353 In-Reply-To: <patchbomb.60@test-hostname>
1390 In-Reply-To: <patchbomb.60@test-hostname>
1354 References: <patchbomb.60@test-hostname>
1391 References: <patchbomb.60@test-hostname>
1355 User-Agent: Mercurial-patchbomb/* (glob)
1392 User-Agent: Mercurial-patchbomb/* (glob)
1356 Date: Thu, 01 Jan 1970 00:01:01 +0000
1393 Date: Thu, 01 Jan 1970 00:01:01 +0000
1357 From: quux
1394 From: quux
1358 To: foo
1395 To: foo
1359 Cc: bar
1396 Cc: bar
1360
1397
1361 --===*= (glob)
1398 --===*= (glob)
1362 MIME-Version: 1.0
1399 MIME-Version: 1.0
1363 Content-Type: text/plain; charset="us-ascii"
1400 Content-Type: text/plain; charset="us-ascii"
1364 Content-Transfer-Encoding: 7bit
1401 Content-Transfer-Encoding: 7bit
1365
1402
1366 Patch subject is complete summary.
1403 Patch subject is complete summary.
1367
1404
1368
1405
1369
1406
1370 --===*= (glob)
1407 --===*= (glob)
1371 MIME-Version: 1.0
1408 MIME-Version: 1.0
1372 Content-Type: text/x-patch; charset="us-ascii"
1409 Content-Type: text/x-patch; charset="us-ascii"
1373 Content-Transfer-Encoding: 7bit
1410 Content-Transfer-Encoding: 7bit
1374 Content-Disposition: attachment; filename=t2-1.patch
1411 Content-Disposition: attachment; filename=t2-1.patch
1375
1412
1376 # HG changeset patch
1413 # HG changeset patch
1377 # User test
1414 # User test
1378 # Date 1 0
1415 # Date 1 0
1379 # Thu Jan 01 00:00:01 1970 +0000
1416 # Thu Jan 01 00:00:01 1970 +0000
1380 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
1417 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
1381 # Parent 0000000000000000000000000000000000000000
1418 # Parent 0000000000000000000000000000000000000000
1382 a
1419 a
1383
1420
1384 diff -r 000000000000 -r 8580ff50825a a
1421 diff -r 000000000000 -r 8580ff50825a a
1385 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1422 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1386 +++ b/a Thu Jan 01 00:00:01 1970 +0000
1423 +++ b/a Thu Jan 01 00:00:01 1970 +0000
1387 @@ -0,0 +1,1 @@
1424 @@ -0,0 +1,1 @@
1388 +a
1425 +a
1389
1426
1390 --===*=-- (glob)
1427 --===*=-- (glob)
1391 displaying [PATCH 2 of 3] b ...
1428 displaying [PATCH 2 of 3] b ...
1392 Content-Type: multipart/mixed; boundary="===*==" (glob)
1429 Content-Type: multipart/mixed; boundary="===*==" (glob)
1393 MIME-Version: 1.0
1430 MIME-Version: 1.0
1394 Subject: [PATCH 2 of 3] b
1431 Subject: [PATCH 2 of 3] b
1395 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1432 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1396 X-Mercurial-Series-Index: 2
1433 X-Mercurial-Series-Index: 2
1397 X-Mercurial-Series-Total: 3
1434 X-Mercurial-Series-Total: 3
1398 Message-Id: <97d72e5f12c7e84f8506.62@test-hostname>
1435 Message-Id: <97d72e5f12c7e84f8506.62@test-hostname>
1399 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
1436 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
1400 In-Reply-To: <patchbomb.60@test-hostname>
1437 In-Reply-To: <patchbomb.60@test-hostname>
1401 References: <patchbomb.60@test-hostname>
1438 References: <patchbomb.60@test-hostname>
1402 User-Agent: Mercurial-patchbomb/* (glob)
1439 User-Agent: Mercurial-patchbomb/* (glob)
1403 Date: Thu, 01 Jan 1970 00:01:02 +0000
1440 Date: Thu, 01 Jan 1970 00:01:02 +0000
1404 From: quux
1441 From: quux
1405 To: foo
1442 To: foo
1406 Cc: bar
1443 Cc: bar
1407
1444
1408 --===*= (glob)
1445 --===*= (glob)
1409 MIME-Version: 1.0
1446 MIME-Version: 1.0
1410 Content-Type: text/plain; charset="us-ascii"
1447 Content-Type: text/plain; charset="us-ascii"
1411 Content-Transfer-Encoding: 7bit
1448 Content-Transfer-Encoding: 7bit
1412
1449
1413 Patch subject is complete summary.
1450 Patch subject is complete summary.
1414
1451
1415
1452
1416
1453
1417 --===*= (glob)
1454 --===*= (glob)
1418 MIME-Version: 1.0
1455 MIME-Version: 1.0
1419 Content-Type: text/x-patch; charset="us-ascii"
1456 Content-Type: text/x-patch; charset="us-ascii"
1420 Content-Transfer-Encoding: 7bit
1457 Content-Transfer-Encoding: 7bit
1421 Content-Disposition: attachment; filename=t2-2.patch
1458 Content-Disposition: attachment; filename=t2-2.patch
1422
1459
1423 # HG changeset patch
1460 # HG changeset patch
1424 # User test
1461 # User test
1425 # Date 2 0
1462 # Date 2 0
1426 # Thu Jan 01 00:00:02 1970 +0000
1463 # Thu Jan 01 00:00:02 1970 +0000
1427 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1464 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1428 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
1465 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
1429 b
1466 b
1430
1467
1431 diff -r 8580ff50825a -r 97d72e5f12c7 b
1468 diff -r 8580ff50825a -r 97d72e5f12c7 b
1432 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1469 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1433 +++ b/b Thu Jan 01 00:00:02 1970 +0000
1470 +++ b/b Thu Jan 01 00:00:02 1970 +0000
1434 @@ -0,0 +1,1 @@
1471 @@ -0,0 +1,1 @@
1435 +b
1472 +b
1436
1473
1437 --===*=-- (glob)
1474 --===*=-- (glob)
1438 displaying [PATCH 3 of 3] long line ...
1475 displaying [PATCH 3 of 3] long line ...
1439 Content-Type: multipart/mixed; boundary="===*==" (glob)
1476 Content-Type: multipart/mixed; boundary="===*==" (glob)
1440 MIME-Version: 1.0
1477 MIME-Version: 1.0
1441 Subject: [PATCH 3 of 3] long line
1478 Subject: [PATCH 3 of 3] long line
1442 X-Mercurial-Node: 0c7b871cb86b61a1c07e244393603c361e4a178d
1479 X-Mercurial-Node: 0c7b871cb86b61a1c07e244393603c361e4a178d
1443 X-Mercurial-Series-Index: 3
1480 X-Mercurial-Series-Index: 3
1444 X-Mercurial-Series-Total: 3
1481 X-Mercurial-Series-Total: 3
1445 Message-Id: <0c7b871cb86b61a1c07e.63@test-hostname>
1482 Message-Id: <0c7b871cb86b61a1c07e.63@test-hostname>
1446 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
1483 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
1447 In-Reply-To: <patchbomb.60@test-hostname>
1484 In-Reply-To: <patchbomb.60@test-hostname>
1448 References: <patchbomb.60@test-hostname>
1485 References: <patchbomb.60@test-hostname>
1449 User-Agent: Mercurial-patchbomb/* (glob)
1486 User-Agent: Mercurial-patchbomb/* (glob)
1450 Date: Thu, 01 Jan 1970 00:01:03 +0000
1487 Date: Thu, 01 Jan 1970 00:01:03 +0000
1451 From: quux
1488 From: quux
1452 To: foo
1489 To: foo
1453 Cc: bar
1490 Cc: bar
1454
1491
1455 --===*= (glob)
1492 --===*= (glob)
1456 MIME-Version: 1.0
1493 MIME-Version: 1.0
1457 Content-Type: text/plain; charset="us-ascii"
1494 Content-Type: text/plain; charset="us-ascii"
1458 Content-Transfer-Encoding: 7bit
1495 Content-Transfer-Encoding: 7bit
1459
1496
1460 Patch subject is complete summary.
1497 Patch subject is complete summary.
1461
1498
1462
1499
1463
1500
1464 --===*= (glob)
1501 --===*= (glob)
1465 MIME-Version: 1.0
1502 MIME-Version: 1.0
1466 Content-Type: text/x-patch; charset="us-ascii"
1503 Content-Type: text/x-patch; charset="us-ascii"
1467 Content-Transfer-Encoding: quoted-printable
1504 Content-Transfer-Encoding: quoted-printable
1468 Content-Disposition: attachment; filename=t2-3.patch
1505 Content-Disposition: attachment; filename=t2-3.patch
1469
1506
1470 # HG changeset patch
1507 # HG changeset patch
1471 # User test
1508 # User test
1472 # Date 4 0
1509 # Date 4 0
1473 # Thu Jan 01 00:00:04 1970 +0000
1510 # Thu Jan 01 00:00:04 1970 +0000
1474 # Node ID 0c7b871cb86b61a1c07e244393603c361e4a178d
1511 # Node ID 0c7b871cb86b61a1c07e244393603c361e4a178d
1475 # Parent f81ef97829467e868fc405fccbcfa66217e4d3e6
1512 # Parent f81ef97829467e868fc405fccbcfa66217e4d3e6
1476 long line
1513 long line
1477
1514
1478 diff -r f81ef9782946 -r 0c7b871cb86b long
1515 diff -r f81ef9782946 -r 0c7b871cb86b long
1479 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1516 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1480 +++ b/long Thu Jan 01 00:00:04 1970 +0000
1517 +++ b/long Thu Jan 01 00:00:04 1970 +0000
1481 @@ -0,0 +1,4 @@
1518 @@ -0,0 +1,4 @@
1482 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1519 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1483 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1520 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1484 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1521 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1485 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1522 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1486 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1523 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1487 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1524 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1488 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1525 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1489 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1526 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1490 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1527 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1491 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1528 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1492 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1529 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1493 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1530 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1494 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1531 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1495 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
1532 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
1496 +foo
1533 +foo
1497 +
1534 +
1498 +bar
1535 +bar
1499
1536
1500 --===*=-- (glob)
1537 --===*=-- (glob)
1501
1538
1502 test intro for single patch:
1539 test intro for single patch:
1503 $ hg email --date '1970-1-1 0:1' -n --intro -f quux -t foo -c bar -s test \
1540 $ hg email --date '1970-1-1 0:1' -n --intro -f quux -t foo -c bar -s test \
1504 > -r 2
1541 > -r 2
1505 this patch series consists of 1 patches.
1542 this patch series consists of 1 patches.
1506
1543
1507
1544
1508 Write the introductory message for the patch series.
1545 Write the introductory message for the patch series.
1509
1546
1510
1547
1511 displaying [PATCH 0 of 1] test ...
1548 displaying [PATCH 0 of 1] test ...
1512 MIME-Version: 1.0
1549 MIME-Version: 1.0
1513 Content-Type: text/plain; charset="us-ascii"
1550 Content-Type: text/plain; charset="us-ascii"
1514 Content-Transfer-Encoding: 7bit
1551 Content-Transfer-Encoding: 7bit
1515 Subject: [PATCH 0 of 1] test
1552 Subject: [PATCH 0 of 1] test
1516 Message-Id: <patchbomb.60@test-hostname>
1553 Message-Id: <patchbomb.60@test-hostname>
1517 User-Agent: Mercurial-patchbomb/* (glob)
1554 User-Agent: Mercurial-patchbomb/* (glob)
1518 Date: Thu, 01 Jan 1970 00:01:00 +0000
1555 Date: Thu, 01 Jan 1970 00:01:00 +0000
1519 From: quux
1556 From: quux
1520 To: foo
1557 To: foo
1521 Cc: bar
1558 Cc: bar
1522
1559
1523
1560
1524 displaying [PATCH 1 of 1] c ...
1561 displaying [PATCH 1 of 1] c ...
1525 MIME-Version: 1.0
1562 MIME-Version: 1.0
1526 Content-Type: text/plain; charset="us-ascii"
1563 Content-Type: text/plain; charset="us-ascii"
1527 Content-Transfer-Encoding: 7bit
1564 Content-Transfer-Encoding: 7bit
1528 Subject: [PATCH 1 of 1] c
1565 Subject: [PATCH 1 of 1] c
1529 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1566 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1530 X-Mercurial-Series-Index: 1
1567 X-Mercurial-Series-Index: 1
1531 X-Mercurial-Series-Total: 1
1568 X-Mercurial-Series-Total: 1
1532 Message-Id: <ff2c9fa2018b15fa74b3.61@test-hostname>
1569 Message-Id: <ff2c9fa2018b15fa74b3.61@test-hostname>
1533 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.61@test-hostname>
1570 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.61@test-hostname>
1534 In-Reply-To: <patchbomb.60@test-hostname>
1571 In-Reply-To: <patchbomb.60@test-hostname>
1535 References: <patchbomb.60@test-hostname>
1572 References: <patchbomb.60@test-hostname>
1536 User-Agent: Mercurial-patchbomb/* (glob)
1573 User-Agent: Mercurial-patchbomb/* (glob)
1537 Date: Thu, 01 Jan 1970 00:01:01 +0000
1574 Date: Thu, 01 Jan 1970 00:01:01 +0000
1538 From: quux
1575 From: quux
1539 To: foo
1576 To: foo
1540 Cc: bar
1577 Cc: bar
1541
1578
1542 # HG changeset patch
1579 # HG changeset patch
1543 # User test
1580 # User test
1544 # Date 3 0
1581 # Date 3 0
1545 # Thu Jan 01 00:00:03 1970 +0000
1582 # Thu Jan 01 00:00:03 1970 +0000
1546 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1583 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1547 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1584 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1548 c
1585 c
1549
1586
1550 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1587 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1551 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1588 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1552 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1589 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1553 @@ -0,0 +1,1 @@
1590 @@ -0,0 +1,1 @@
1554 +c
1591 +c
1555
1592
1556
1593
1557 test --desc without --intro for a single patch:
1594 test --desc without --intro for a single patch:
1558 $ echo foo > intro.text
1595 $ echo foo > intro.text
1559 $ hg email --date '1970-1-1 0:1' -n --desc intro.text -f quux -t foo -c bar \
1596 $ hg email --date '1970-1-1 0:1' -n --desc intro.text -f quux -t foo -c bar \
1560 > -s test -r 2
1597 > -s test -r 2
1561 this patch series consists of 1 patches.
1598 this patch series consists of 1 patches.
1562
1599
1563
1600
1564 displaying [PATCH 0 of 1] test ...
1601 displaying [PATCH 0 of 1] test ...
1565 MIME-Version: 1.0
1602 MIME-Version: 1.0
1566 Content-Type: text/plain; charset="us-ascii"
1603 Content-Type: text/plain; charset="us-ascii"
1567 Content-Transfer-Encoding: 7bit
1604 Content-Transfer-Encoding: 7bit
1568 Subject: [PATCH 0 of 1] test
1605 Subject: [PATCH 0 of 1] test
1569 Message-Id: <patchbomb.60@test-hostname>
1606 Message-Id: <patchbomb.60@test-hostname>
1570 User-Agent: Mercurial-patchbomb/* (glob)
1607 User-Agent: Mercurial-patchbomb/* (glob)
1571 Date: Thu, 01 Jan 1970 00:01:00 +0000
1608 Date: Thu, 01 Jan 1970 00:01:00 +0000
1572 From: quux
1609 From: quux
1573 To: foo
1610 To: foo
1574 Cc: bar
1611 Cc: bar
1575
1612
1576 foo
1613 foo
1577
1614
1578 displaying [PATCH 1 of 1] c ...
1615 displaying [PATCH 1 of 1] c ...
1579 MIME-Version: 1.0
1616 MIME-Version: 1.0
1580 Content-Type: text/plain; charset="us-ascii"
1617 Content-Type: text/plain; charset="us-ascii"
1581 Content-Transfer-Encoding: 7bit
1618 Content-Transfer-Encoding: 7bit
1582 Subject: [PATCH 1 of 1] c
1619 Subject: [PATCH 1 of 1] c
1583 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1620 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1584 X-Mercurial-Series-Index: 1
1621 X-Mercurial-Series-Index: 1
1585 X-Mercurial-Series-Total: 1
1622 X-Mercurial-Series-Total: 1
1586 Message-Id: <ff2c9fa2018b15fa74b3.61@test-hostname>
1623 Message-Id: <ff2c9fa2018b15fa74b3.61@test-hostname>
1587 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.61@test-hostname>
1624 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.61@test-hostname>
1588 In-Reply-To: <patchbomb.60@test-hostname>
1625 In-Reply-To: <patchbomb.60@test-hostname>
1589 References: <patchbomb.60@test-hostname>
1626 References: <patchbomb.60@test-hostname>
1590 User-Agent: Mercurial-patchbomb/* (glob)
1627 User-Agent: Mercurial-patchbomb/* (glob)
1591 Date: Thu, 01 Jan 1970 00:01:01 +0000
1628 Date: Thu, 01 Jan 1970 00:01:01 +0000
1592 From: quux
1629 From: quux
1593 To: foo
1630 To: foo
1594 Cc: bar
1631 Cc: bar
1595
1632
1596 # HG changeset patch
1633 # HG changeset patch
1597 # User test
1634 # User test
1598 # Date 3 0
1635 # Date 3 0
1599 # Thu Jan 01 00:00:03 1970 +0000
1636 # Thu Jan 01 00:00:03 1970 +0000
1600 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1637 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1601 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1638 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1602 c
1639 c
1603
1640
1604 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1641 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1605 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1642 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1606 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1643 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1607 @@ -0,0 +1,1 @@
1644 @@ -0,0 +1,1 @@
1608 +c
1645 +c
1609
1646
1610
1647
1611 test intro for multiple patches:
1648 test intro for multiple patches:
1612 $ hg email --date '1970-1-1 0:1' -n --intro -f quux -t foo -c bar -s test \
1649 $ hg email --date '1970-1-1 0:1' -n --intro -f quux -t foo -c bar -s test \
1613 > -r 0:1
1650 > -r 0:1
1614 this patch series consists of 2 patches.
1651 this patch series consists of 2 patches.
1615
1652
1616
1653
1617 Write the introductory message for the patch series.
1654 Write the introductory message for the patch series.
1618
1655
1619
1656
1620 displaying [PATCH 0 of 2] test ...
1657 displaying [PATCH 0 of 2] test ...
1621 MIME-Version: 1.0
1658 MIME-Version: 1.0
1622 Content-Type: text/plain; charset="us-ascii"
1659 Content-Type: text/plain; charset="us-ascii"
1623 Content-Transfer-Encoding: 7bit
1660 Content-Transfer-Encoding: 7bit
1624 Subject: [PATCH 0 of 2] test
1661 Subject: [PATCH 0 of 2] test
1625 Message-Id: <patchbomb.60@test-hostname>
1662 Message-Id: <patchbomb.60@test-hostname>
1626 User-Agent: Mercurial-patchbomb/* (glob)
1663 User-Agent: Mercurial-patchbomb/* (glob)
1627 Date: Thu, 01 Jan 1970 00:01:00 +0000
1664 Date: Thu, 01 Jan 1970 00:01:00 +0000
1628 From: quux
1665 From: quux
1629 To: foo
1666 To: foo
1630 Cc: bar
1667 Cc: bar
1631
1668
1632
1669
1633 displaying [PATCH 1 of 2] a ...
1670 displaying [PATCH 1 of 2] a ...
1634 MIME-Version: 1.0
1671 MIME-Version: 1.0
1635 Content-Type: text/plain; charset="us-ascii"
1672 Content-Type: text/plain; charset="us-ascii"
1636 Content-Transfer-Encoding: 7bit
1673 Content-Transfer-Encoding: 7bit
1637 Subject: [PATCH 1 of 2] a
1674 Subject: [PATCH 1 of 2] a
1638 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
1675 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
1639 X-Mercurial-Series-Index: 1
1676 X-Mercurial-Series-Index: 1
1640 X-Mercurial-Series-Total: 2
1677 X-Mercurial-Series-Total: 2
1641 Message-Id: <8580ff50825a50c8f716.61@test-hostname>
1678 Message-Id: <8580ff50825a50c8f716.61@test-hostname>
1642 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
1679 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
1643 In-Reply-To: <patchbomb.60@test-hostname>
1680 In-Reply-To: <patchbomb.60@test-hostname>
1644 References: <patchbomb.60@test-hostname>
1681 References: <patchbomb.60@test-hostname>
1645 User-Agent: Mercurial-patchbomb/* (glob)
1682 User-Agent: Mercurial-patchbomb/* (glob)
1646 Date: Thu, 01 Jan 1970 00:01:01 +0000
1683 Date: Thu, 01 Jan 1970 00:01:01 +0000
1647 From: quux
1684 From: quux
1648 To: foo
1685 To: foo
1649 Cc: bar
1686 Cc: bar
1650
1687
1651 # HG changeset patch
1688 # HG changeset patch
1652 # User test
1689 # User test
1653 # Date 1 0
1690 # Date 1 0
1654 # Thu Jan 01 00:00:01 1970 +0000
1691 # Thu Jan 01 00:00:01 1970 +0000
1655 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
1692 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
1656 # Parent 0000000000000000000000000000000000000000
1693 # Parent 0000000000000000000000000000000000000000
1657 a
1694 a
1658
1695
1659 diff -r 000000000000 -r 8580ff50825a a
1696 diff -r 000000000000 -r 8580ff50825a a
1660 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1697 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1661 +++ b/a Thu Jan 01 00:00:01 1970 +0000
1698 +++ b/a Thu Jan 01 00:00:01 1970 +0000
1662 @@ -0,0 +1,1 @@
1699 @@ -0,0 +1,1 @@
1663 +a
1700 +a
1664
1701
1665 displaying [PATCH 2 of 2] b ...
1702 displaying [PATCH 2 of 2] b ...
1666 MIME-Version: 1.0
1703 MIME-Version: 1.0
1667 Content-Type: text/plain; charset="us-ascii"
1704 Content-Type: text/plain; charset="us-ascii"
1668 Content-Transfer-Encoding: 7bit
1705 Content-Transfer-Encoding: 7bit
1669 Subject: [PATCH 2 of 2] b
1706 Subject: [PATCH 2 of 2] b
1670 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1707 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1671 X-Mercurial-Series-Index: 2
1708 X-Mercurial-Series-Index: 2
1672 X-Mercurial-Series-Total: 2
1709 X-Mercurial-Series-Total: 2
1673 Message-Id: <97d72e5f12c7e84f8506.62@test-hostname>
1710 Message-Id: <97d72e5f12c7e84f8506.62@test-hostname>
1674 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
1711 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
1675 In-Reply-To: <patchbomb.60@test-hostname>
1712 In-Reply-To: <patchbomb.60@test-hostname>
1676 References: <patchbomb.60@test-hostname>
1713 References: <patchbomb.60@test-hostname>
1677 User-Agent: Mercurial-patchbomb/* (glob)
1714 User-Agent: Mercurial-patchbomb/* (glob)
1678 Date: Thu, 01 Jan 1970 00:01:02 +0000
1715 Date: Thu, 01 Jan 1970 00:01:02 +0000
1679 From: quux
1716 From: quux
1680 To: foo
1717 To: foo
1681 Cc: bar
1718 Cc: bar
1682
1719
1683 # HG changeset patch
1720 # HG changeset patch
1684 # User test
1721 # User test
1685 # Date 2 0
1722 # Date 2 0
1686 # Thu Jan 01 00:00:02 1970 +0000
1723 # Thu Jan 01 00:00:02 1970 +0000
1687 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1724 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1688 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
1725 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
1689 b
1726 b
1690
1727
1691 diff -r 8580ff50825a -r 97d72e5f12c7 b
1728 diff -r 8580ff50825a -r 97d72e5f12c7 b
1692 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1729 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1693 +++ b/b Thu Jan 01 00:00:02 1970 +0000
1730 +++ b/b Thu Jan 01 00:00:02 1970 +0000
1694 @@ -0,0 +1,1 @@
1731 @@ -0,0 +1,1 @@
1695 +b
1732 +b
1696
1733
1697
1734
1698 test reply-to via config:
1735 test reply-to via config:
1699 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -r 2 \
1736 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -r 2 \
1700 > --config patchbomb.reply-to='baz@example.com'
1737 > --config patchbomb.reply-to='baz@example.com'
1701 this patch series consists of 1 patches.
1738 this patch series consists of 1 patches.
1702
1739
1703
1740
1704 displaying [PATCH] test ...
1741 displaying [PATCH] test ...
1705 MIME-Version: 1.0
1742 MIME-Version: 1.0
1706 Content-Type: text/plain; charset="us-ascii"
1743 Content-Type: text/plain; charset="us-ascii"
1707 Content-Transfer-Encoding: 7bit
1744 Content-Transfer-Encoding: 7bit
1708 Subject: [PATCH] test
1745 Subject: [PATCH] test
1709 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1746 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1710 X-Mercurial-Series-Index: 1
1747 X-Mercurial-Series-Index: 1
1711 X-Mercurial-Series-Total: 1
1748 X-Mercurial-Series-Total: 1
1712 Message-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
1749 Message-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
1713 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
1750 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
1714 User-Agent: Mercurial-patchbomb/* (glob)
1751 User-Agent: Mercurial-patchbomb/* (glob)
1715 Date: Thu, 01 Jan 1970 00:01:00 +0000
1752 Date: Thu, 01 Jan 1970 00:01:00 +0000
1716 From: quux
1753 From: quux
1717 To: foo
1754 To: foo
1718 Cc: bar
1755 Cc: bar
1719 Reply-To: baz@example.com
1756 Reply-To: baz@example.com
1720
1757
1721 # HG changeset patch
1758 # HG changeset patch
1722 # User test
1759 # User test
1723 # Date 3 0
1760 # Date 3 0
1724 # Thu Jan 01 00:00:03 1970 +0000
1761 # Thu Jan 01 00:00:03 1970 +0000
1725 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1762 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1726 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1763 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1727 c
1764 c
1728
1765
1729 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1766 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1730 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1767 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1731 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1768 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1732 @@ -0,0 +1,1 @@
1769 @@ -0,0 +1,1 @@
1733 +c
1770 +c
1734
1771
1735
1772
1736 test reply-to via command line:
1773 test reply-to via command line:
1737 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -r 2 \
1774 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -r 2 \
1738 > --reply-to baz --reply-to fred
1775 > --reply-to baz --reply-to fred
1739 this patch series consists of 1 patches.
1776 this patch series consists of 1 patches.
1740
1777
1741
1778
1742 displaying [PATCH] test ...
1779 displaying [PATCH] test ...
1743 MIME-Version: 1.0
1780 MIME-Version: 1.0
1744 Content-Type: text/plain; charset="us-ascii"
1781 Content-Type: text/plain; charset="us-ascii"
1745 Content-Transfer-Encoding: 7bit
1782 Content-Transfer-Encoding: 7bit
1746 Subject: [PATCH] test
1783 Subject: [PATCH] test
1747 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1784 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1748 X-Mercurial-Series-Index: 1
1785 X-Mercurial-Series-Index: 1
1749 X-Mercurial-Series-Total: 1
1786 X-Mercurial-Series-Total: 1
1750 Message-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
1787 Message-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
1751 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
1788 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
1752 User-Agent: Mercurial-patchbomb/* (glob)
1789 User-Agent: Mercurial-patchbomb/* (glob)
1753 Date: Thu, 01 Jan 1970 00:01:00 +0000
1790 Date: Thu, 01 Jan 1970 00:01:00 +0000
1754 From: quux
1791 From: quux
1755 To: foo
1792 To: foo
1756 Cc: bar
1793 Cc: bar
1757 Reply-To: baz, fred
1794 Reply-To: baz, fred
1758
1795
1759 # HG changeset patch
1796 # HG changeset patch
1760 # User test
1797 # User test
1761 # Date 3 0
1798 # Date 3 0
1762 # Thu Jan 01 00:00:03 1970 +0000
1799 # Thu Jan 01 00:00:03 1970 +0000
1763 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1800 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1764 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1801 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1765 c
1802 c
1766
1803
1767 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1804 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1768 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1805 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1769 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1806 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1770 @@ -0,0 +1,1 @@
1807 @@ -0,0 +1,1 @@
1771 +c
1808 +c
1772
1809
1773
1810
1774 tagging csets:
1811 tagging csets:
1775 $ hg tag -r0 zero zero.foo
1812 $ hg tag -r0 zero zero.foo
1776 $ hg tag -r1 one one.patch
1813 $ hg tag -r1 one one.patch
1777 $ hg tag -r2 two two.diff
1814 $ hg tag -r2 two two.diff
1778
1815
1779 test inline for single named patch:
1816 test inline for single named patch:
1780 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -i \
1817 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -i \
1781 > -r 2 | filterboundary
1818 > -r 2 | filterboundary
1782 this patch series consists of 1 patches.
1819 this patch series consists of 1 patches.
1783
1820
1784
1821
1785 displaying [PATCH] test ...
1822 displaying [PATCH] test ...
1786 Content-Type: multipart/mixed; boundary="===*==" (glob)
1823 Content-Type: multipart/mixed; boundary="===*==" (glob)
1787 MIME-Version: 1.0
1824 MIME-Version: 1.0
1788 Subject: [PATCH] test
1825 Subject: [PATCH] test
1789 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1826 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1790 X-Mercurial-Series-Index: 1
1827 X-Mercurial-Series-Index: 1
1791 X-Mercurial-Series-Total: 1
1828 X-Mercurial-Series-Total: 1
1792 Message-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
1829 Message-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
1793 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
1830 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
1794 User-Agent: Mercurial-patchbomb/* (glob)
1831 User-Agent: Mercurial-patchbomb/* (glob)
1795 Date: Thu, 01 Jan 1970 00:01:00 +0000
1832 Date: Thu, 01 Jan 1970 00:01:00 +0000
1796 From: quux
1833 From: quux
1797 To: foo
1834 To: foo
1798 Cc: bar
1835 Cc: bar
1799
1836
1800 --===*= (glob)
1837 --===*= (glob)
1801 MIME-Version: 1.0
1838 MIME-Version: 1.0
1802 Content-Type: text/x-patch; charset="us-ascii"
1839 Content-Type: text/x-patch; charset="us-ascii"
1803 Content-Transfer-Encoding: 7bit
1840 Content-Transfer-Encoding: 7bit
1804 Content-Disposition: inline; filename=two.diff
1841 Content-Disposition: inline; filename=two.diff
1805
1842
1806 # HG changeset patch
1843 # HG changeset patch
1807 # User test
1844 # User test
1808 # Date 3 0
1845 # Date 3 0
1809 # Thu Jan 01 00:00:03 1970 +0000
1846 # Thu Jan 01 00:00:03 1970 +0000
1810 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1847 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1811 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1848 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1812 c
1849 c
1813
1850
1814 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1851 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1815 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1852 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1816 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1853 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1817 @@ -0,0 +1,1 @@
1854 @@ -0,0 +1,1 @@
1818 +c
1855 +c
1819
1856
1820 --===*=-- (glob)
1857 --===*=-- (glob)
1821
1858
1822 test inline for multiple named/unnamed patches:
1859 test inline for multiple named/unnamed patches:
1823 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -i \
1860 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -i \
1824 > -r 0:1 | filterboundary
1861 > -r 0:1 | filterboundary
1825 this patch series consists of 2 patches.
1862 this patch series consists of 2 patches.
1826
1863
1827
1864
1828 Write the introductory message for the patch series.
1865 Write the introductory message for the patch series.
1829
1866
1830
1867
1831 displaying [PATCH 0 of 2] test ...
1868 displaying [PATCH 0 of 2] test ...
1832 MIME-Version: 1.0
1869 MIME-Version: 1.0
1833 Content-Type: text/plain; charset="us-ascii"
1870 Content-Type: text/plain; charset="us-ascii"
1834 Content-Transfer-Encoding: 7bit
1871 Content-Transfer-Encoding: 7bit
1835 Subject: [PATCH 0 of 2] test
1872 Subject: [PATCH 0 of 2] test
1836 Message-Id: <patchbomb.60@test-hostname>
1873 Message-Id: <patchbomb.60@test-hostname>
1837 User-Agent: Mercurial-patchbomb/* (glob)
1874 User-Agent: Mercurial-patchbomb/* (glob)
1838 Date: Thu, 01 Jan 1970 00:01:00 +0000
1875 Date: Thu, 01 Jan 1970 00:01:00 +0000
1839 From: quux
1876 From: quux
1840 To: foo
1877 To: foo
1841 Cc: bar
1878 Cc: bar
1842
1879
1843
1880
1844 displaying [PATCH 1 of 2] a ...
1881 displaying [PATCH 1 of 2] a ...
1845 Content-Type: multipart/mixed; boundary="===*==" (glob)
1882 Content-Type: multipart/mixed; boundary="===*==" (glob)
1846 MIME-Version: 1.0
1883 MIME-Version: 1.0
1847 Subject: [PATCH 1 of 2] a
1884 Subject: [PATCH 1 of 2] a
1848 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
1885 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
1849 X-Mercurial-Series-Index: 1
1886 X-Mercurial-Series-Index: 1
1850 X-Mercurial-Series-Total: 2
1887 X-Mercurial-Series-Total: 2
1851 Message-Id: <8580ff50825a50c8f716.61@test-hostname>
1888 Message-Id: <8580ff50825a50c8f716.61@test-hostname>
1852 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
1889 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
1853 In-Reply-To: <patchbomb.60@test-hostname>
1890 In-Reply-To: <patchbomb.60@test-hostname>
1854 References: <patchbomb.60@test-hostname>
1891 References: <patchbomb.60@test-hostname>
1855 User-Agent: Mercurial-patchbomb/* (glob)
1892 User-Agent: Mercurial-patchbomb/* (glob)
1856 Date: Thu, 01 Jan 1970 00:01:01 +0000
1893 Date: Thu, 01 Jan 1970 00:01:01 +0000
1857 From: quux
1894 From: quux
1858 To: foo
1895 To: foo
1859 Cc: bar
1896 Cc: bar
1860
1897
1861 --===*= (glob)
1898 --===*= (glob)
1862 MIME-Version: 1.0
1899 MIME-Version: 1.0
1863 Content-Type: text/x-patch; charset="us-ascii"
1900 Content-Type: text/x-patch; charset="us-ascii"
1864 Content-Transfer-Encoding: 7bit
1901 Content-Transfer-Encoding: 7bit
1865 Content-Disposition: inline; filename=t2-1.patch
1902 Content-Disposition: inline; filename=t2-1.patch
1866
1903
1867 # HG changeset patch
1904 # HG changeset patch
1868 # User test
1905 # User test
1869 # Date 1 0
1906 # Date 1 0
1870 # Thu Jan 01 00:00:01 1970 +0000
1907 # Thu Jan 01 00:00:01 1970 +0000
1871 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
1908 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
1872 # Parent 0000000000000000000000000000000000000000
1909 # Parent 0000000000000000000000000000000000000000
1873 a
1910 a
1874
1911
1875 diff -r 000000000000 -r 8580ff50825a a
1912 diff -r 000000000000 -r 8580ff50825a a
1876 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1913 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1877 +++ b/a Thu Jan 01 00:00:01 1970 +0000
1914 +++ b/a Thu Jan 01 00:00:01 1970 +0000
1878 @@ -0,0 +1,1 @@
1915 @@ -0,0 +1,1 @@
1879 +a
1916 +a
1880
1917
1881 --===*=-- (glob)
1918 --===*=-- (glob)
1882 displaying [PATCH 2 of 2] b ...
1919 displaying [PATCH 2 of 2] b ...
1883 Content-Type: multipart/mixed; boundary="===*==" (glob)
1920 Content-Type: multipart/mixed; boundary="===*==" (glob)
1884 MIME-Version: 1.0
1921 MIME-Version: 1.0
1885 Subject: [PATCH 2 of 2] b
1922 Subject: [PATCH 2 of 2] b
1886 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1923 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1887 X-Mercurial-Series-Index: 2
1924 X-Mercurial-Series-Index: 2
1888 X-Mercurial-Series-Total: 2
1925 X-Mercurial-Series-Total: 2
1889 Message-Id: <97d72e5f12c7e84f8506.62@test-hostname>
1926 Message-Id: <97d72e5f12c7e84f8506.62@test-hostname>
1890 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
1927 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
1891 In-Reply-To: <patchbomb.60@test-hostname>
1928 In-Reply-To: <patchbomb.60@test-hostname>
1892 References: <patchbomb.60@test-hostname>
1929 References: <patchbomb.60@test-hostname>
1893 User-Agent: Mercurial-patchbomb/* (glob)
1930 User-Agent: Mercurial-patchbomb/* (glob)
1894 Date: Thu, 01 Jan 1970 00:01:02 +0000
1931 Date: Thu, 01 Jan 1970 00:01:02 +0000
1895 From: quux
1932 From: quux
1896 To: foo
1933 To: foo
1897 Cc: bar
1934 Cc: bar
1898
1935
1899 --===*= (glob)
1936 --===*= (glob)
1900 MIME-Version: 1.0
1937 MIME-Version: 1.0
1901 Content-Type: text/x-patch; charset="us-ascii"
1938 Content-Type: text/x-patch; charset="us-ascii"
1902 Content-Transfer-Encoding: 7bit
1939 Content-Transfer-Encoding: 7bit
1903 Content-Disposition: inline; filename=one.patch
1940 Content-Disposition: inline; filename=one.patch
1904
1941
1905 # HG changeset patch
1942 # HG changeset patch
1906 # User test
1943 # User test
1907 # Date 2 0
1944 # Date 2 0
1908 # Thu Jan 01 00:00:02 1970 +0000
1945 # Thu Jan 01 00:00:02 1970 +0000
1909 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1946 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1910 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
1947 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
1911 b
1948 b
1912
1949
1913 diff -r 8580ff50825a -r 97d72e5f12c7 b
1950 diff -r 8580ff50825a -r 97d72e5f12c7 b
1914 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1951 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1915 +++ b/b Thu Jan 01 00:00:02 1970 +0000
1952 +++ b/b Thu Jan 01 00:00:02 1970 +0000
1916 @@ -0,0 +1,1 @@
1953 @@ -0,0 +1,1 @@
1917 +b
1954 +b
1918
1955
1919 --===*=-- (glob)
1956 --===*=-- (glob)
1920
1957
1921
1958
1922 test inreplyto:
1959 test inreplyto:
1923 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar --in-reply-to baz \
1960 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar --in-reply-to baz \
1924 > -r tip
1961 > -r tip
1925 this patch series consists of 1 patches.
1962 this patch series consists of 1 patches.
1926
1963
1927
1964
1928 displaying [PATCH] Added tag two, two.diff for changeset ff2c9fa2018b ...
1965 displaying [PATCH] Added tag two, two.diff for changeset ff2c9fa2018b ...
1929 MIME-Version: 1.0
1966 MIME-Version: 1.0
1930 Content-Type: text/plain; charset="us-ascii"
1967 Content-Type: text/plain; charset="us-ascii"
1931 Content-Transfer-Encoding: 7bit
1968 Content-Transfer-Encoding: 7bit
1932 Subject: [PATCH] Added tag two, two.diff for changeset ff2c9fa2018b
1969 Subject: [PATCH] Added tag two, two.diff for changeset ff2c9fa2018b
1933 X-Mercurial-Node: 9cea7492c36bdda2c72e7dd5f35f7fc367adeb2c
1970 X-Mercurial-Node: 9cea7492c36bdda2c72e7dd5f35f7fc367adeb2c
1934 X-Mercurial-Series-Index: 1
1971 X-Mercurial-Series-Index: 1
1935 X-Mercurial-Series-Total: 1
1972 X-Mercurial-Series-Total: 1
1936 Message-Id: <9cea7492c36bdda2c72e.60@test-hostname>
1973 Message-Id: <9cea7492c36bdda2c72e.60@test-hostname>
1937 X-Mercurial-Series-Id: <9cea7492c36bdda2c72e.60@test-hostname>
1974 X-Mercurial-Series-Id: <9cea7492c36bdda2c72e.60@test-hostname>
1938 In-Reply-To: <baz>
1975 In-Reply-To: <baz>
1939 References: <baz>
1976 References: <baz>
1940 User-Agent: Mercurial-patchbomb/* (glob)
1977 User-Agent: Mercurial-patchbomb/* (glob)
1941 Date: Thu, 01 Jan 1970 00:01:00 +0000
1978 Date: Thu, 01 Jan 1970 00:01:00 +0000
1942 From: quux
1979 From: quux
1943 To: foo
1980 To: foo
1944 Cc: bar
1981 Cc: bar
1945
1982
1946 # HG changeset patch
1983 # HG changeset patch
1947 # User test
1984 # User test
1948 # Date 0 0
1985 # Date 0 0
1949 # Thu Jan 01 00:00:00 1970 +0000
1986 # Thu Jan 01 00:00:00 1970 +0000
1950 # Node ID 9cea7492c36bdda2c72e7dd5f35f7fc367adeb2c
1987 # Node ID 9cea7492c36bdda2c72e7dd5f35f7fc367adeb2c
1951 # Parent 3b775b32716d9b54291ccddf0a36ceea45449bfb
1988 # Parent 3b775b32716d9b54291ccddf0a36ceea45449bfb
1952 Added tag two, two.diff for changeset ff2c9fa2018b
1989 Added tag two, two.diff for changeset ff2c9fa2018b
1953
1990
1954 diff -r 3b775b32716d -r 9cea7492c36b .hgtags
1991 diff -r 3b775b32716d -r 9cea7492c36b .hgtags
1955 --- a/.hgtags Thu Jan 01 00:00:00 1970 +0000
1992 --- a/.hgtags Thu Jan 01 00:00:00 1970 +0000
1956 +++ b/.hgtags Thu Jan 01 00:00:00 1970 +0000
1993 +++ b/.hgtags Thu Jan 01 00:00:00 1970 +0000
1957 @@ -2,3 +2,5 @@
1994 @@ -2,3 +2,5 @@
1958 8580ff50825a50c8f716709acdf8de0deddcd6ab zero.foo
1995 8580ff50825a50c8f716709acdf8de0deddcd6ab zero.foo
1959 97d72e5f12c7e84f85064aa72e5a297142c36ed9 one
1996 97d72e5f12c7e84f85064aa72e5a297142c36ed9 one
1960 97d72e5f12c7e84f85064aa72e5a297142c36ed9 one.patch
1997 97d72e5f12c7e84f85064aa72e5a297142c36ed9 one.patch
1961 +ff2c9fa2018b15fa74b33363bda9527323e2a99f two
1998 +ff2c9fa2018b15fa74b33363bda9527323e2a99f two
1962 +ff2c9fa2018b15fa74b33363bda9527323e2a99f two.diff
1999 +ff2c9fa2018b15fa74b33363bda9527323e2a99f two.diff
1963
2000
1964 no intro message in non-interactive mode
2001 no intro message in non-interactive mode
1965 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar --in-reply-to baz \
2002 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar --in-reply-to baz \
1966 > -r 0:1
2003 > -r 0:1
1967 this patch series consists of 2 patches.
2004 this patch series consists of 2 patches.
1968
2005
1969 (optional) Subject: [PATCH 0 of 2]
2006 (optional) Subject: [PATCH 0 of 2]
1970
2007
1971 displaying [PATCH 1 of 2] a ...
2008 displaying [PATCH 1 of 2] a ...
1972 MIME-Version: 1.0
2009 MIME-Version: 1.0
1973 Content-Type: text/plain; charset="us-ascii"
2010 Content-Type: text/plain; charset="us-ascii"
1974 Content-Transfer-Encoding: 7bit
2011 Content-Transfer-Encoding: 7bit
1975 Subject: [PATCH 1 of 2] a
2012 Subject: [PATCH 1 of 2] a
1976 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
2013 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
1977 X-Mercurial-Series-Index: 1
2014 X-Mercurial-Series-Index: 1
1978 X-Mercurial-Series-Total: 2
2015 X-Mercurial-Series-Total: 2
1979 Message-Id: <8580ff50825a50c8f716.60@test-hostname>
2016 Message-Id: <8580ff50825a50c8f716.60@test-hostname>
1980 X-Mercurial-Series-Id: <8580ff50825a50c8f716.60@test-hostname>
2017 X-Mercurial-Series-Id: <8580ff50825a50c8f716.60@test-hostname>
1981 In-Reply-To: <baz>
2018 In-Reply-To: <baz>
1982 References: <baz>
2019 References: <baz>
1983 User-Agent: Mercurial-patchbomb/* (glob)
2020 User-Agent: Mercurial-patchbomb/* (glob)
1984 Date: Thu, 01 Jan 1970 00:01:00 +0000
2021 Date: Thu, 01 Jan 1970 00:01:00 +0000
1985 From: quux
2022 From: quux
1986 To: foo
2023 To: foo
1987 Cc: bar
2024 Cc: bar
1988
2025
1989 # HG changeset patch
2026 # HG changeset patch
1990 # User test
2027 # User test
1991 # Date 1 0
2028 # Date 1 0
1992 # Thu Jan 01 00:00:01 1970 +0000
2029 # Thu Jan 01 00:00:01 1970 +0000
1993 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
2030 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
1994 # Parent 0000000000000000000000000000000000000000
2031 # Parent 0000000000000000000000000000000000000000
1995 a
2032 a
1996
2033
1997 diff -r 000000000000 -r 8580ff50825a a
2034 diff -r 000000000000 -r 8580ff50825a a
1998 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2035 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1999 +++ b/a Thu Jan 01 00:00:01 1970 +0000
2036 +++ b/a Thu Jan 01 00:00:01 1970 +0000
2000 @@ -0,0 +1,1 @@
2037 @@ -0,0 +1,1 @@
2001 +a
2038 +a
2002
2039
2003 displaying [PATCH 2 of 2] b ...
2040 displaying [PATCH 2 of 2] b ...
2004 MIME-Version: 1.0
2041 MIME-Version: 1.0
2005 Content-Type: text/plain; charset="us-ascii"
2042 Content-Type: text/plain; charset="us-ascii"
2006 Content-Transfer-Encoding: 7bit
2043 Content-Transfer-Encoding: 7bit
2007 Subject: [PATCH 2 of 2] b
2044 Subject: [PATCH 2 of 2] b
2008 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2045 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2009 X-Mercurial-Series-Index: 2
2046 X-Mercurial-Series-Index: 2
2010 X-Mercurial-Series-Total: 2
2047 X-Mercurial-Series-Total: 2
2011 Message-Id: <97d72e5f12c7e84f8506.61@test-hostname>
2048 Message-Id: <97d72e5f12c7e84f8506.61@test-hostname>
2012 X-Mercurial-Series-Id: <8580ff50825a50c8f716.60@test-hostname>
2049 X-Mercurial-Series-Id: <8580ff50825a50c8f716.60@test-hostname>
2013 In-Reply-To: <baz>
2050 In-Reply-To: <baz>
2014 References: <baz>
2051 References: <baz>
2015 User-Agent: Mercurial-patchbomb/* (glob)
2052 User-Agent: Mercurial-patchbomb/* (glob)
2016 Date: Thu, 01 Jan 1970 00:01:01 +0000
2053 Date: Thu, 01 Jan 1970 00:01:01 +0000
2017 From: quux
2054 From: quux
2018 To: foo
2055 To: foo
2019 Cc: bar
2056 Cc: bar
2020
2057
2021 # HG changeset patch
2058 # HG changeset patch
2022 # User test
2059 # User test
2023 # Date 2 0
2060 # Date 2 0
2024 # Thu Jan 01 00:00:02 1970 +0000
2061 # Thu Jan 01 00:00:02 1970 +0000
2025 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2062 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2026 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
2063 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
2027 b
2064 b
2028
2065
2029 diff -r 8580ff50825a -r 97d72e5f12c7 b
2066 diff -r 8580ff50825a -r 97d72e5f12c7 b
2030 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2067 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2031 +++ b/b Thu Jan 01 00:00:02 1970 +0000
2068 +++ b/b Thu Jan 01 00:00:02 1970 +0000
2032 @@ -0,0 +1,1 @@
2069 @@ -0,0 +1,1 @@
2033 +b
2070 +b
2034
2071
2035
2072
2036
2073
2037
2074
2038 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar --in-reply-to baz \
2075 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar --in-reply-to baz \
2039 > -s test -r 0:1
2076 > -s test -r 0:1
2040 this patch series consists of 2 patches.
2077 this patch series consists of 2 patches.
2041
2078
2042
2079
2043 Write the introductory message for the patch series.
2080 Write the introductory message for the patch series.
2044
2081
2045
2082
2046 displaying [PATCH 0 of 2] test ...
2083 displaying [PATCH 0 of 2] test ...
2047 MIME-Version: 1.0
2084 MIME-Version: 1.0
2048 Content-Type: text/plain; charset="us-ascii"
2085 Content-Type: text/plain; charset="us-ascii"
2049 Content-Transfer-Encoding: 7bit
2086 Content-Transfer-Encoding: 7bit
2050 Subject: [PATCH 0 of 2] test
2087 Subject: [PATCH 0 of 2] test
2051 Message-Id: <patchbomb.60@test-hostname>
2088 Message-Id: <patchbomb.60@test-hostname>
2052 In-Reply-To: <baz>
2089 In-Reply-To: <baz>
2053 References: <baz>
2090 References: <baz>
2054 User-Agent: Mercurial-patchbomb/* (glob)
2091 User-Agent: Mercurial-patchbomb/* (glob)
2055 Date: Thu, 01 Jan 1970 00:01:00 +0000
2092 Date: Thu, 01 Jan 1970 00:01:00 +0000
2056 From: quux
2093 From: quux
2057 To: foo
2094 To: foo
2058 Cc: bar
2095 Cc: bar
2059
2096
2060
2097
2061 displaying [PATCH 1 of 2] a ...
2098 displaying [PATCH 1 of 2] a ...
2062 MIME-Version: 1.0
2099 MIME-Version: 1.0
2063 Content-Type: text/plain; charset="us-ascii"
2100 Content-Type: text/plain; charset="us-ascii"
2064 Content-Transfer-Encoding: 7bit
2101 Content-Transfer-Encoding: 7bit
2065 Subject: [PATCH 1 of 2] a
2102 Subject: [PATCH 1 of 2] a
2066 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
2103 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
2067 X-Mercurial-Series-Index: 1
2104 X-Mercurial-Series-Index: 1
2068 X-Mercurial-Series-Total: 2
2105 X-Mercurial-Series-Total: 2
2069 Message-Id: <8580ff50825a50c8f716.61@test-hostname>
2106 Message-Id: <8580ff50825a50c8f716.61@test-hostname>
2070 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
2107 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
2071 In-Reply-To: <patchbomb.60@test-hostname>
2108 In-Reply-To: <patchbomb.60@test-hostname>
2072 References: <patchbomb.60@test-hostname>
2109 References: <patchbomb.60@test-hostname>
2073 User-Agent: Mercurial-patchbomb/* (glob)
2110 User-Agent: Mercurial-patchbomb/* (glob)
2074 Date: Thu, 01 Jan 1970 00:01:01 +0000
2111 Date: Thu, 01 Jan 1970 00:01:01 +0000
2075 From: quux
2112 From: quux
2076 To: foo
2113 To: foo
2077 Cc: bar
2114 Cc: bar
2078
2115
2079 # HG changeset patch
2116 # HG changeset patch
2080 # User test
2117 # User test
2081 # Date 1 0
2118 # Date 1 0
2082 # Thu Jan 01 00:00:01 1970 +0000
2119 # Thu Jan 01 00:00:01 1970 +0000
2083 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
2120 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
2084 # Parent 0000000000000000000000000000000000000000
2121 # Parent 0000000000000000000000000000000000000000
2085 a
2122 a
2086
2123
2087 diff -r 000000000000 -r 8580ff50825a a
2124 diff -r 000000000000 -r 8580ff50825a a
2088 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2125 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2089 +++ b/a Thu Jan 01 00:00:01 1970 +0000
2126 +++ b/a Thu Jan 01 00:00:01 1970 +0000
2090 @@ -0,0 +1,1 @@
2127 @@ -0,0 +1,1 @@
2091 +a
2128 +a
2092
2129
2093 displaying [PATCH 2 of 2] b ...
2130 displaying [PATCH 2 of 2] b ...
2094 MIME-Version: 1.0
2131 MIME-Version: 1.0
2095 Content-Type: text/plain; charset="us-ascii"
2132 Content-Type: text/plain; charset="us-ascii"
2096 Content-Transfer-Encoding: 7bit
2133 Content-Transfer-Encoding: 7bit
2097 Subject: [PATCH 2 of 2] b
2134 Subject: [PATCH 2 of 2] b
2098 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2135 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2099 X-Mercurial-Series-Index: 2
2136 X-Mercurial-Series-Index: 2
2100 X-Mercurial-Series-Total: 2
2137 X-Mercurial-Series-Total: 2
2101 Message-Id: <97d72e5f12c7e84f8506.62@test-hostname>
2138 Message-Id: <97d72e5f12c7e84f8506.62@test-hostname>
2102 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
2139 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
2103 In-Reply-To: <patchbomb.60@test-hostname>
2140 In-Reply-To: <patchbomb.60@test-hostname>
2104 References: <patchbomb.60@test-hostname>
2141 References: <patchbomb.60@test-hostname>
2105 User-Agent: Mercurial-patchbomb/* (glob)
2142 User-Agent: Mercurial-patchbomb/* (glob)
2106 Date: Thu, 01 Jan 1970 00:01:02 +0000
2143 Date: Thu, 01 Jan 1970 00:01:02 +0000
2107 From: quux
2144 From: quux
2108 To: foo
2145 To: foo
2109 Cc: bar
2146 Cc: bar
2110
2147
2111 # HG changeset patch
2148 # HG changeset patch
2112 # User test
2149 # User test
2113 # Date 2 0
2150 # Date 2 0
2114 # Thu Jan 01 00:00:02 1970 +0000
2151 # Thu Jan 01 00:00:02 1970 +0000
2115 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2152 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2116 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
2153 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
2117 b
2154 b
2118
2155
2119 diff -r 8580ff50825a -r 97d72e5f12c7 b
2156 diff -r 8580ff50825a -r 97d72e5f12c7 b
2120 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2157 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2121 +++ b/b Thu Jan 01 00:00:02 1970 +0000
2158 +++ b/b Thu Jan 01 00:00:02 1970 +0000
2122 @@ -0,0 +1,1 @@
2159 @@ -0,0 +1,1 @@
2123 +b
2160 +b
2124
2161
2125
2162
2126 test single flag for single patch (and no warning when not mailing dirty rev):
2163 test single flag for single patch (and no warning when not mailing dirty rev):
2127 $ hg up -qr1
2164 $ hg up -qr1
2128 $ echo dirt > a
2165 $ echo dirt > a
2129 $ hg email --date '1970-1-1 0:1' -n --flag fooFlag -f quux -t foo -c bar -s test \
2166 $ hg email --date '1970-1-1 0:1' -n --flag fooFlag -f quux -t foo -c bar -s test \
2130 > -r 2 | filterboundary
2167 > -r 2 | filterboundary
2131 this patch series consists of 1 patches.
2168 this patch series consists of 1 patches.
2132
2169
2133
2170
2134 displaying [PATCH fooFlag] test ...
2171 displaying [PATCH fooFlag] test ...
2135 MIME-Version: 1.0
2172 MIME-Version: 1.0
2136 Content-Type: text/plain; charset="us-ascii"
2173 Content-Type: text/plain; charset="us-ascii"
2137 Content-Transfer-Encoding: 7bit
2174 Content-Transfer-Encoding: 7bit
2138 Subject: [PATCH fooFlag] test
2175 Subject: [PATCH fooFlag] test
2139 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
2176 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
2140 X-Mercurial-Series-Index: 1
2177 X-Mercurial-Series-Index: 1
2141 X-Mercurial-Series-Total: 1
2178 X-Mercurial-Series-Total: 1
2142 Message-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
2179 Message-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
2143 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
2180 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
2144 User-Agent: Mercurial-patchbomb/* (glob)
2181 User-Agent: Mercurial-patchbomb/* (glob)
2145 Date: Thu, 01 Jan 1970 00:01:00 +0000
2182 Date: Thu, 01 Jan 1970 00:01:00 +0000
2146 From: quux
2183 From: quux
2147 To: foo
2184 To: foo
2148 Cc: bar
2185 Cc: bar
2149
2186
2150 # HG changeset patch
2187 # HG changeset patch
2151 # User test
2188 # User test
2152 # Date 3 0
2189 # Date 3 0
2153 # Thu Jan 01 00:00:03 1970 +0000
2190 # Thu Jan 01 00:00:03 1970 +0000
2154 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
2191 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
2155 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2192 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2156 c
2193 c
2157
2194
2158 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
2195 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
2159 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2196 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2160 +++ b/c Thu Jan 01 00:00:03 1970 +0000
2197 +++ b/c Thu Jan 01 00:00:03 1970 +0000
2161 @@ -0,0 +1,1 @@
2198 @@ -0,0 +1,1 @@
2162 +c
2199 +c
2163
2200
2164
2201
2165 test single flag for multiple patches (and warning when mailing dirty rev):
2202 test single flag for multiple patches (and warning when mailing dirty rev):
2166 $ hg email --date '1970-1-1 0:1' -n --flag fooFlag -f quux -t foo -c bar -s test \
2203 $ hg email --date '1970-1-1 0:1' -n --flag fooFlag -f quux -t foo -c bar -s test \
2167 > -r 0:1
2204 > -r 0:1
2168 warning: working directory has uncommitted changes
2205 warning: working directory has uncommitted changes
2169 this patch series consists of 2 patches.
2206 this patch series consists of 2 patches.
2170
2207
2171
2208
2172 Write the introductory message for the patch series.
2209 Write the introductory message for the patch series.
2173
2210
2174
2211
2175 displaying [PATCH 0 of 2 fooFlag] test ...
2212 displaying [PATCH 0 of 2 fooFlag] test ...
2176 MIME-Version: 1.0
2213 MIME-Version: 1.0
2177 Content-Type: text/plain; charset="us-ascii"
2214 Content-Type: text/plain; charset="us-ascii"
2178 Content-Transfer-Encoding: 7bit
2215 Content-Transfer-Encoding: 7bit
2179 Subject: [PATCH 0 of 2 fooFlag] test
2216 Subject: [PATCH 0 of 2 fooFlag] test
2180 Message-Id: <patchbomb.60@test-hostname>
2217 Message-Id: <patchbomb.60@test-hostname>
2181 User-Agent: Mercurial-patchbomb/* (glob)
2218 User-Agent: Mercurial-patchbomb/* (glob)
2182 Date: Thu, 01 Jan 1970 00:01:00 +0000
2219 Date: Thu, 01 Jan 1970 00:01:00 +0000
2183 From: quux
2220 From: quux
2184 To: foo
2221 To: foo
2185 Cc: bar
2222 Cc: bar
2186
2223
2187
2224
2188 displaying [PATCH 1 of 2 fooFlag] a ...
2225 displaying [PATCH 1 of 2 fooFlag] a ...
2189 MIME-Version: 1.0
2226 MIME-Version: 1.0
2190 Content-Type: text/plain; charset="us-ascii"
2227 Content-Type: text/plain; charset="us-ascii"
2191 Content-Transfer-Encoding: 7bit
2228 Content-Transfer-Encoding: 7bit
2192 Subject: [PATCH 1 of 2 fooFlag] a
2229 Subject: [PATCH 1 of 2 fooFlag] a
2193 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
2230 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
2194 X-Mercurial-Series-Index: 1
2231 X-Mercurial-Series-Index: 1
2195 X-Mercurial-Series-Total: 2
2232 X-Mercurial-Series-Total: 2
2196 Message-Id: <8580ff50825a50c8f716.61@test-hostname>
2233 Message-Id: <8580ff50825a50c8f716.61@test-hostname>
2197 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
2234 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
2198 In-Reply-To: <patchbomb.60@test-hostname>
2235 In-Reply-To: <patchbomb.60@test-hostname>
2199 References: <patchbomb.60@test-hostname>
2236 References: <patchbomb.60@test-hostname>
2200 User-Agent: Mercurial-patchbomb/* (glob)
2237 User-Agent: Mercurial-patchbomb/* (glob)
2201 Date: Thu, 01 Jan 1970 00:01:01 +0000
2238 Date: Thu, 01 Jan 1970 00:01:01 +0000
2202 From: quux
2239 From: quux
2203 To: foo
2240 To: foo
2204 Cc: bar
2241 Cc: bar
2205
2242
2206 # HG changeset patch
2243 # HG changeset patch
2207 # User test
2244 # User test
2208 # Date 1 0
2245 # Date 1 0
2209 # Thu Jan 01 00:00:01 1970 +0000
2246 # Thu Jan 01 00:00:01 1970 +0000
2210 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
2247 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
2211 # Parent 0000000000000000000000000000000000000000
2248 # Parent 0000000000000000000000000000000000000000
2212 a
2249 a
2213
2250
2214 diff -r 000000000000 -r 8580ff50825a a
2251 diff -r 000000000000 -r 8580ff50825a a
2215 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2252 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2216 +++ b/a Thu Jan 01 00:00:01 1970 +0000
2253 +++ b/a Thu Jan 01 00:00:01 1970 +0000
2217 @@ -0,0 +1,1 @@
2254 @@ -0,0 +1,1 @@
2218 +a
2255 +a
2219
2256
2220 displaying [PATCH 2 of 2 fooFlag] b ...
2257 displaying [PATCH 2 of 2 fooFlag] b ...
2221 MIME-Version: 1.0
2258 MIME-Version: 1.0
2222 Content-Type: text/plain; charset="us-ascii"
2259 Content-Type: text/plain; charset="us-ascii"
2223 Content-Transfer-Encoding: 7bit
2260 Content-Transfer-Encoding: 7bit
2224 Subject: [PATCH 2 of 2 fooFlag] b
2261 Subject: [PATCH 2 of 2 fooFlag] b
2225 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2262 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2226 X-Mercurial-Series-Index: 2
2263 X-Mercurial-Series-Index: 2
2227 X-Mercurial-Series-Total: 2
2264 X-Mercurial-Series-Total: 2
2228 Message-Id: <97d72e5f12c7e84f8506.62@test-hostname>
2265 Message-Id: <97d72e5f12c7e84f8506.62@test-hostname>
2229 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
2266 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
2230 In-Reply-To: <patchbomb.60@test-hostname>
2267 In-Reply-To: <patchbomb.60@test-hostname>
2231 References: <patchbomb.60@test-hostname>
2268 References: <patchbomb.60@test-hostname>
2232 User-Agent: Mercurial-patchbomb/* (glob)
2269 User-Agent: Mercurial-patchbomb/* (glob)
2233 Date: Thu, 01 Jan 1970 00:01:02 +0000
2270 Date: Thu, 01 Jan 1970 00:01:02 +0000
2234 From: quux
2271 From: quux
2235 To: foo
2272 To: foo
2236 Cc: bar
2273 Cc: bar
2237
2274
2238 # HG changeset patch
2275 # HG changeset patch
2239 # User test
2276 # User test
2240 # Date 2 0
2277 # Date 2 0
2241 # Thu Jan 01 00:00:02 1970 +0000
2278 # Thu Jan 01 00:00:02 1970 +0000
2242 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2279 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2243 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
2280 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
2244 b
2281 b
2245
2282
2246 diff -r 8580ff50825a -r 97d72e5f12c7 b
2283 diff -r 8580ff50825a -r 97d72e5f12c7 b
2247 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2284 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2248 +++ b/b Thu Jan 01 00:00:02 1970 +0000
2285 +++ b/b Thu Jan 01 00:00:02 1970 +0000
2249 @@ -0,0 +1,1 @@
2286 @@ -0,0 +1,1 @@
2250 +b
2287 +b
2251
2288
2252 $ hg revert --no-b a
2289 $ hg revert --no-b a
2253 $ hg up -q
2290 $ hg up -q
2254
2291
2255 test multiple flags for single patch:
2292 test multiple flags for single patch:
2256 $ hg email --date '1970-1-1 0:1' -n --flag fooFlag --flag barFlag -f quux -t foo \
2293 $ hg email --date '1970-1-1 0:1' -n --flag fooFlag --flag barFlag -f quux -t foo \
2257 > -c bar -s test -r 2
2294 > -c bar -s test -r 2
2258 this patch series consists of 1 patches.
2295 this patch series consists of 1 patches.
2259
2296
2260
2297
2261 displaying [PATCH fooFlag barFlag] test ...
2298 displaying [PATCH fooFlag barFlag] test ...
2262 MIME-Version: 1.0
2299 MIME-Version: 1.0
2263 Content-Type: text/plain; charset="us-ascii"
2300 Content-Type: text/plain; charset="us-ascii"
2264 Content-Transfer-Encoding: 7bit
2301 Content-Transfer-Encoding: 7bit
2265 Subject: [PATCH fooFlag barFlag] test
2302 Subject: [PATCH fooFlag barFlag] test
2266 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
2303 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
2267 X-Mercurial-Series-Index: 1
2304 X-Mercurial-Series-Index: 1
2268 X-Mercurial-Series-Total: 1
2305 X-Mercurial-Series-Total: 1
2269 Message-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
2306 Message-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
2270 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
2307 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.60@test-hostname>
2271 User-Agent: Mercurial-patchbomb/* (glob)
2308 User-Agent: Mercurial-patchbomb/* (glob)
2272 Date: Thu, 01 Jan 1970 00:01:00 +0000
2309 Date: Thu, 01 Jan 1970 00:01:00 +0000
2273 From: quux
2310 From: quux
2274 To: foo
2311 To: foo
2275 Cc: bar
2312 Cc: bar
2276
2313
2277 # HG changeset patch
2314 # HG changeset patch
2278 # User test
2315 # User test
2279 # Date 3 0
2316 # Date 3 0
2280 # Thu Jan 01 00:00:03 1970 +0000
2317 # Thu Jan 01 00:00:03 1970 +0000
2281 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
2318 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
2282 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2319 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2283 c
2320 c
2284
2321
2285 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
2322 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
2286 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2323 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2287 +++ b/c Thu Jan 01 00:00:03 1970 +0000
2324 +++ b/c Thu Jan 01 00:00:03 1970 +0000
2288 @@ -0,0 +1,1 @@
2325 @@ -0,0 +1,1 @@
2289 +c
2326 +c
2290
2327
2291
2328
2292 test multiple flags for multiple patches:
2329 test multiple flags for multiple patches:
2293 $ hg email --date '1970-1-1 0:1' -n --flag fooFlag --flag barFlag -f quux -t foo \
2330 $ hg email --date '1970-1-1 0:1' -n --flag fooFlag --flag barFlag -f quux -t foo \
2294 > -c bar -s test -r 0:1
2331 > -c bar -s test -r 0:1
2295 this patch series consists of 2 patches.
2332 this patch series consists of 2 patches.
2296
2333
2297
2334
2298 Write the introductory message for the patch series.
2335 Write the introductory message for the patch series.
2299
2336
2300
2337
2301 displaying [PATCH 0 of 2 fooFlag barFlag] test ...
2338 displaying [PATCH 0 of 2 fooFlag barFlag] test ...
2302 MIME-Version: 1.0
2339 MIME-Version: 1.0
2303 Content-Type: text/plain; charset="us-ascii"
2340 Content-Type: text/plain; charset="us-ascii"
2304 Content-Transfer-Encoding: 7bit
2341 Content-Transfer-Encoding: 7bit
2305 Subject: [PATCH 0 of 2 fooFlag barFlag] test
2342 Subject: [PATCH 0 of 2 fooFlag barFlag] test
2306 Message-Id: <patchbomb.60@test-hostname>
2343 Message-Id: <patchbomb.60@test-hostname>
2307 User-Agent: Mercurial-patchbomb/* (glob)
2344 User-Agent: Mercurial-patchbomb/* (glob)
2308 Date: Thu, 01 Jan 1970 00:01:00 +0000
2345 Date: Thu, 01 Jan 1970 00:01:00 +0000
2309 From: quux
2346 From: quux
2310 To: foo
2347 To: foo
2311 Cc: bar
2348 Cc: bar
2312
2349
2313
2350
2314 displaying [PATCH 1 of 2 fooFlag barFlag] a ...
2351 displaying [PATCH 1 of 2 fooFlag barFlag] a ...
2315 MIME-Version: 1.0
2352 MIME-Version: 1.0
2316 Content-Type: text/plain; charset="us-ascii"
2353 Content-Type: text/plain; charset="us-ascii"
2317 Content-Transfer-Encoding: 7bit
2354 Content-Transfer-Encoding: 7bit
2318 Subject: [PATCH 1 of 2 fooFlag barFlag] a
2355 Subject: [PATCH 1 of 2 fooFlag barFlag] a
2319 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
2356 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
2320 X-Mercurial-Series-Index: 1
2357 X-Mercurial-Series-Index: 1
2321 X-Mercurial-Series-Total: 2
2358 X-Mercurial-Series-Total: 2
2322 Message-Id: <8580ff50825a50c8f716.61@test-hostname>
2359 Message-Id: <8580ff50825a50c8f716.61@test-hostname>
2323 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
2360 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
2324 In-Reply-To: <patchbomb.60@test-hostname>
2361 In-Reply-To: <patchbomb.60@test-hostname>
2325 References: <patchbomb.60@test-hostname>
2362 References: <patchbomb.60@test-hostname>
2326 User-Agent: Mercurial-patchbomb/* (glob)
2363 User-Agent: Mercurial-patchbomb/* (glob)
2327 Date: Thu, 01 Jan 1970 00:01:01 +0000
2364 Date: Thu, 01 Jan 1970 00:01:01 +0000
2328 From: quux
2365 From: quux
2329 To: foo
2366 To: foo
2330 Cc: bar
2367 Cc: bar
2331
2368
2332 # HG changeset patch
2369 # HG changeset patch
2333 # User test
2370 # User test
2334 # Date 1 0
2371 # Date 1 0
2335 # Thu Jan 01 00:00:01 1970 +0000
2372 # Thu Jan 01 00:00:01 1970 +0000
2336 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
2373 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
2337 # Parent 0000000000000000000000000000000000000000
2374 # Parent 0000000000000000000000000000000000000000
2338 a
2375 a
2339
2376
2340 diff -r 000000000000 -r 8580ff50825a a
2377 diff -r 000000000000 -r 8580ff50825a a
2341 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2378 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2342 +++ b/a Thu Jan 01 00:00:01 1970 +0000
2379 +++ b/a Thu Jan 01 00:00:01 1970 +0000
2343 @@ -0,0 +1,1 @@
2380 @@ -0,0 +1,1 @@
2344 +a
2381 +a
2345
2382
2346 displaying [PATCH 2 of 2 fooFlag barFlag] b ...
2383 displaying [PATCH 2 of 2 fooFlag barFlag] b ...
2347 MIME-Version: 1.0
2384 MIME-Version: 1.0
2348 Content-Type: text/plain; charset="us-ascii"
2385 Content-Type: text/plain; charset="us-ascii"
2349 Content-Transfer-Encoding: 7bit
2386 Content-Transfer-Encoding: 7bit
2350 Subject: [PATCH 2 of 2 fooFlag barFlag] b
2387 Subject: [PATCH 2 of 2 fooFlag barFlag] b
2351 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2388 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2352 X-Mercurial-Series-Index: 2
2389 X-Mercurial-Series-Index: 2
2353 X-Mercurial-Series-Total: 2
2390 X-Mercurial-Series-Total: 2
2354 Message-Id: <97d72e5f12c7e84f8506.62@test-hostname>
2391 Message-Id: <97d72e5f12c7e84f8506.62@test-hostname>
2355 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
2392 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
2356 In-Reply-To: <patchbomb.60@test-hostname>
2393 In-Reply-To: <patchbomb.60@test-hostname>
2357 References: <patchbomb.60@test-hostname>
2394 References: <patchbomb.60@test-hostname>
2358 User-Agent: Mercurial-patchbomb/* (glob)
2395 User-Agent: Mercurial-patchbomb/* (glob)
2359 Date: Thu, 01 Jan 1970 00:01:02 +0000
2396 Date: Thu, 01 Jan 1970 00:01:02 +0000
2360 From: quux
2397 From: quux
2361 To: foo
2398 To: foo
2362 Cc: bar
2399 Cc: bar
2363
2400
2364 # HG changeset patch
2401 # HG changeset patch
2365 # User test
2402 # User test
2366 # Date 2 0
2403 # Date 2 0
2367 # Thu Jan 01 00:00:02 1970 +0000
2404 # Thu Jan 01 00:00:02 1970 +0000
2368 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2405 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2369 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
2406 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
2370 b
2407 b
2371
2408
2372 diff -r 8580ff50825a -r 97d72e5f12c7 b
2409 diff -r 8580ff50825a -r 97d72e5f12c7 b
2373 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2410 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2374 +++ b/b Thu Jan 01 00:00:02 1970 +0000
2411 +++ b/b Thu Jan 01 00:00:02 1970 +0000
2375 @@ -0,0 +1,1 @@
2412 @@ -0,0 +1,1 @@
2376 +b
2413 +b
2377
2414
2378
2415
2379 test multi-address parsing:
2416 test multi-address parsing:
2380 $ hg email --date '1980-1-1 0:1' -m tmp.mbox -f quux -t 'spam<spam><eggs>' \
2417 $ hg email --date '1980-1-1 0:1' -m tmp.mbox -f quux -t 'spam<spam><eggs>' \
2381 > -t toast -c 'foo,bar@example.com' -c '"A, B <>" <a@example.com>' -s test -r 0 \
2418 > -t toast -c 'foo,bar@example.com' -c '"A, B <>" <a@example.com>' -s test -r 0 \
2382 > --config email.bcc='"Quux, A." <quux>'
2419 > --config email.bcc='"Quux, A." <quux>'
2383 this patch series consists of 1 patches.
2420 this patch series consists of 1 patches.
2384
2421
2385
2422
2386 sending [PATCH] test ...
2423 sending [PATCH] test ...
2387 $ cat < tmp.mbox
2424 $ cat < tmp.mbox
2388 From quux ... ... .. ..:..:.. .... (re)
2425 From quux ... ... .. ..:..:.. .... (re)
2389 MIME-Version: 1.0
2426 MIME-Version: 1.0
2390 Content-Type: text/plain; charset="us-ascii"
2427 Content-Type: text/plain; charset="us-ascii"
2391 Content-Transfer-Encoding: 7bit
2428 Content-Transfer-Encoding: 7bit
2392 Subject: [PATCH] test
2429 Subject: [PATCH] test
2393 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
2430 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
2394 X-Mercurial-Series-Index: 1
2431 X-Mercurial-Series-Index: 1
2395 X-Mercurial-Series-Total: 1
2432 X-Mercurial-Series-Total: 1
2396 Message-Id: <8580ff50825a50c8f716.315532860@test-hostname>
2433 Message-Id: <8580ff50825a50c8f716.315532860@test-hostname>
2397 X-Mercurial-Series-Id: <8580ff50825a50c8f716.315532860@test-hostname>
2434 X-Mercurial-Series-Id: <8580ff50825a50c8f716.315532860@test-hostname>
2398 User-Agent: Mercurial-patchbomb/* (glob)
2435 User-Agent: Mercurial-patchbomb/* (glob)
2399 Date: Tue, 01 Jan 1980 00:01:00 +0000
2436 Date: Tue, 01 Jan 1980 00:01:00 +0000
2400 From: quux
2437 From: quux
2401 To: =?iso-8859-1?q?spam?= <spam>, eggs, toast (py3 !)
2438 To: =?iso-8859-1?q?spam?= <spam>, eggs, toast (py3 !)
2402 Cc: foo, bar@example.com, =?iso-8859-1?q?A=2C_B_=3C=3E?= <a@example.com> (py3 !)
2439 Cc: foo, bar@example.com, =?iso-8859-1?q?A=2C_B_=3C=3E?= <a@example.com> (py3 !)
2403 Bcc: =?iso-8859-1?q?Quux=2C_A=2E?= <quux> (py3 !)
2440 Bcc: =?iso-8859-1?q?Quux=2C_A=2E?= <quux> (py3 !)
2404
2441
2405 # HG changeset patch
2442 # HG changeset patch
2406 # User test
2443 # User test
2407 # Date 1 0
2444 # Date 1 0
2408 # Thu Jan 01 00:00:01 1970 +0000
2445 # Thu Jan 01 00:00:01 1970 +0000
2409 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
2446 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
2410 # Parent 0000000000000000000000000000000000000000
2447 # Parent 0000000000000000000000000000000000000000
2411 a
2448 a
2412
2449
2413 diff -r 000000000000 -r 8580ff50825a a
2450 diff -r 000000000000 -r 8580ff50825a a
2414 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2451 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2415 +++ b/a Thu Jan 01 00:00:01 1970 +0000
2452 +++ b/a Thu Jan 01 00:00:01 1970 +0000
2416 @@ -0,0 +1,1 @@
2453 @@ -0,0 +1,1 @@
2417 +a
2454 +a
2418
2455
2419
2456
2420
2457
2421 test flag template:
2458 test flag template:
2422 $ echo foo > intro.text
2459 $ echo foo > intro.text
2423 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -r 0:1 \
2460 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -r 0:1 \
2424 > --desc intro.text --subject test \
2461 > --desc intro.text --subject test \
2425 > --config patchbomb.flagtemplate='R{rev}'
2462 > --config patchbomb.flagtemplate='R{rev}'
2426 this patch series consists of 2 patches.
2463 this patch series consists of 2 patches.
2427
2464
2428 Cc:
2465 Cc:
2429
2466
2430 displaying [PATCH 0 of 2 R1] test ...
2467 displaying [PATCH 0 of 2 R1] test ...
2431 MIME-Version: 1.0
2468 MIME-Version: 1.0
2432 Content-Type: text/plain; charset="us-ascii"
2469 Content-Type: text/plain; charset="us-ascii"
2433 Content-Transfer-Encoding: 7bit
2470 Content-Transfer-Encoding: 7bit
2434 Subject: [PATCH 0 of 2 R1] test
2471 Subject: [PATCH 0 of 2 R1] test
2435 Message-Id: <patchbomb.60@test-hostname>
2472 Message-Id: <patchbomb.60@test-hostname>
2436 User-Agent: Mercurial-patchbomb/* (glob)
2473 User-Agent: Mercurial-patchbomb/* (glob)
2437 Date: Thu, 01 Jan 1970 00:01:00 +0000
2474 Date: Thu, 01 Jan 1970 00:01:00 +0000
2438 From: quux
2475 From: quux
2439 To: foo
2476 To: foo
2440
2477
2441 foo
2478 foo
2442
2479
2443 displaying [PATCH 1 of 2 R0] a ...
2480 displaying [PATCH 1 of 2 R0] a ...
2444 MIME-Version: 1.0
2481 MIME-Version: 1.0
2445 Content-Type: text/plain; charset="us-ascii"
2482 Content-Type: text/plain; charset="us-ascii"
2446 Content-Transfer-Encoding: 7bit
2483 Content-Transfer-Encoding: 7bit
2447 Subject: [PATCH 1 of 2 R0] a
2484 Subject: [PATCH 1 of 2 R0] a
2448 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
2485 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
2449 X-Mercurial-Series-Index: 1
2486 X-Mercurial-Series-Index: 1
2450 X-Mercurial-Series-Total: 2
2487 X-Mercurial-Series-Total: 2
2451 Message-Id: <8580ff50825a50c8f716.61@test-hostname>
2488 Message-Id: <8580ff50825a50c8f716.61@test-hostname>
2452 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
2489 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
2453 In-Reply-To: <patchbomb.60@test-hostname>
2490 In-Reply-To: <patchbomb.60@test-hostname>
2454 References: <patchbomb.60@test-hostname>
2491 References: <patchbomb.60@test-hostname>
2455 User-Agent: Mercurial-patchbomb/* (glob)
2492 User-Agent: Mercurial-patchbomb/* (glob)
2456 Date: Thu, 01 Jan 1970 00:01:01 +0000
2493 Date: Thu, 01 Jan 1970 00:01:01 +0000
2457 From: quux
2494 From: quux
2458 To: foo
2495 To: foo
2459
2496
2460 # HG changeset patch
2497 # HG changeset patch
2461 # User test
2498 # User test
2462 # Date 1 0
2499 # Date 1 0
2463 # Thu Jan 01 00:00:01 1970 +0000
2500 # Thu Jan 01 00:00:01 1970 +0000
2464 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
2501 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
2465 # Parent 0000000000000000000000000000000000000000
2502 # Parent 0000000000000000000000000000000000000000
2466 a
2503 a
2467
2504
2468 diff -r 000000000000 -r 8580ff50825a a
2505 diff -r 000000000000 -r 8580ff50825a a
2469 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2506 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2470 +++ b/a Thu Jan 01 00:00:01 1970 +0000
2507 +++ b/a Thu Jan 01 00:00:01 1970 +0000
2471 @@ -0,0 +1,1 @@
2508 @@ -0,0 +1,1 @@
2472 +a
2509 +a
2473
2510
2474 displaying [PATCH 2 of 2 R1] b ...
2511 displaying [PATCH 2 of 2 R1] b ...
2475 MIME-Version: 1.0
2512 MIME-Version: 1.0
2476 Content-Type: text/plain; charset="us-ascii"
2513 Content-Type: text/plain; charset="us-ascii"
2477 Content-Transfer-Encoding: 7bit
2514 Content-Transfer-Encoding: 7bit
2478 Subject: [PATCH 2 of 2 R1] b
2515 Subject: [PATCH 2 of 2 R1] b
2479 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2516 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2480 X-Mercurial-Series-Index: 2
2517 X-Mercurial-Series-Index: 2
2481 X-Mercurial-Series-Total: 2
2518 X-Mercurial-Series-Total: 2
2482 Message-Id: <97d72e5f12c7e84f8506.62@test-hostname>
2519 Message-Id: <97d72e5f12c7e84f8506.62@test-hostname>
2483 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
2520 X-Mercurial-Series-Id: <8580ff50825a50c8f716.61@test-hostname>
2484 In-Reply-To: <patchbomb.60@test-hostname>
2521 In-Reply-To: <patchbomb.60@test-hostname>
2485 References: <patchbomb.60@test-hostname>
2522 References: <patchbomb.60@test-hostname>
2486 User-Agent: Mercurial-patchbomb/* (glob)
2523 User-Agent: Mercurial-patchbomb/* (glob)
2487 Date: Thu, 01 Jan 1970 00:01:02 +0000
2524 Date: Thu, 01 Jan 1970 00:01:02 +0000
2488 From: quux
2525 From: quux
2489 To: foo
2526 To: foo
2490
2527
2491 # HG changeset patch
2528 # HG changeset patch
2492 # User test
2529 # User test
2493 # Date 2 0
2530 # Date 2 0
2494 # Thu Jan 01 00:00:02 1970 +0000
2531 # Thu Jan 01 00:00:02 1970 +0000
2495 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2532 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2496 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
2533 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
2497 b
2534 b
2498
2535
2499 diff -r 8580ff50825a -r 97d72e5f12c7 b
2536 diff -r 8580ff50825a -r 97d72e5f12c7 b
2500 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2537 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2501 +++ b/b Thu Jan 01 00:00:02 1970 +0000
2538 +++ b/b Thu Jan 01 00:00:02 1970 +0000
2502 @@ -0,0 +1,1 @@
2539 @@ -0,0 +1,1 @@
2503 +b
2540 +b
2504
2541
2505
2542
2506 test flag template plus --flag:
2543 test flag template plus --flag:
2507 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -r 0 --flag 'V2' \
2544 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -r 0 --flag 'V2' \
2508 > --config patchbomb.flagtemplate='{branch} {flags}'
2545 > --config patchbomb.flagtemplate='{branch} {flags}'
2509 this patch series consists of 1 patches.
2546 this patch series consists of 1 patches.
2510
2547
2511 Cc:
2548 Cc:
2512
2549
2513 displaying [PATCH default V2] a ...
2550 displaying [PATCH default V2] a ...
2514 MIME-Version: 1.0
2551 MIME-Version: 1.0
2515 Content-Type: text/plain; charset="us-ascii"
2552 Content-Type: text/plain; charset="us-ascii"
2516 Content-Transfer-Encoding: 7bit
2553 Content-Transfer-Encoding: 7bit
2517 Subject: [PATCH default V2] a
2554 Subject: [PATCH default V2] a
2518 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
2555 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
2519 X-Mercurial-Series-Index: 1
2556 X-Mercurial-Series-Index: 1
2520 X-Mercurial-Series-Total: 1
2557 X-Mercurial-Series-Total: 1
2521 Message-Id: <8580ff50825a50c8f716.60@test-hostname>
2558 Message-Id: <8580ff50825a50c8f716.60@test-hostname>
2522 X-Mercurial-Series-Id: <8580ff50825a50c8f716.60@test-hostname>
2559 X-Mercurial-Series-Id: <8580ff50825a50c8f716.60@test-hostname>
2523 User-Agent: Mercurial-patchbomb/* (glob)
2560 User-Agent: Mercurial-patchbomb/* (glob)
2524 Date: Thu, 01 Jan 1970 00:01:00 +0000
2561 Date: Thu, 01 Jan 1970 00:01:00 +0000
2525 From: quux
2562 From: quux
2526 To: foo
2563 To: foo
2527
2564
2528 # HG changeset patch
2565 # HG changeset patch
2529 # User test
2566 # User test
2530 # Date 1 0
2567 # Date 1 0
2531 # Thu Jan 01 00:00:01 1970 +0000
2568 # Thu Jan 01 00:00:01 1970 +0000
2532 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
2569 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
2533 # Parent 0000000000000000000000000000000000000000
2570 # Parent 0000000000000000000000000000000000000000
2534 a
2571 a
2535
2572
2536 diff -r 000000000000 -r 8580ff50825a a
2573 diff -r 000000000000 -r 8580ff50825a a
2537 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2574 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2538 +++ b/a Thu Jan 01 00:00:01 1970 +0000
2575 +++ b/a Thu Jan 01 00:00:01 1970 +0000
2539 @@ -0,0 +1,1 @@
2576 @@ -0,0 +1,1 @@
2540 +a
2577 +a
2541
2578
2542
2579
2543 test multi-byte domain parsing:
2580 test multi-byte domain parsing:
2544 >>> with open('toaddress.txt', 'wb') as f:
2581 >>> with open('toaddress.txt', 'wb') as f:
2545 ... f.write(b'bar@\xfcnicode.com') and None
2582 ... f.write(b'bar@\xfcnicode.com') and None
2546 $ HGENCODING=iso-8859-1
2583 $ HGENCODING=iso-8859-1
2547 $ export HGENCODING
2584 $ export HGENCODING
2548 $ hg email --date '1980-1-1 0:1' -m tmp.mbox -f quux -t "`cat toaddress.txt`" -s test -r 0
2585 $ hg email --date '1980-1-1 0:1' -m tmp.mbox -f quux -t "`cat toaddress.txt`" -s test -r 0
2549 this patch series consists of 1 patches.
2586 this patch series consists of 1 patches.
2550
2587
2551 Cc:
2588 Cc:
2552
2589
2553 sending [PATCH] test ...
2590 sending [PATCH] test ...
2554
2591
2555 $ cat tmp.mbox
2592 $ cat tmp.mbox
2556 From quux ... ... .. ..:..:.. .... (re)
2593 From quux ... ... .. ..:..:.. .... (re)
2557 MIME-Version: 1.0
2594 MIME-Version: 1.0
2558 Content-Type: text/plain; charset="us-ascii"
2595 Content-Type: text/plain; charset="us-ascii"
2559 Content-Transfer-Encoding: 7bit
2596 Content-Transfer-Encoding: 7bit
2560 Subject: [PATCH] test
2597 Subject: [PATCH] test
2561 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
2598 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
2562 X-Mercurial-Series-Index: 1
2599 X-Mercurial-Series-Index: 1
2563 X-Mercurial-Series-Total: 1
2600 X-Mercurial-Series-Total: 1
2564 Message-Id: <8580ff50825a50c8f716.315532860@test-hostname>
2601 Message-Id: <8580ff50825a50c8f716.315532860@test-hostname>
2565 X-Mercurial-Series-Id: <8580ff50825a50c8f716.315532860@test-hostname>
2602 X-Mercurial-Series-Id: <8580ff50825a50c8f716.315532860@test-hostname>
2566 User-Agent: Mercurial-patchbomb/* (glob)
2603 User-Agent: Mercurial-patchbomb/* (glob)
2567 Date: Tue, 01 Jan 1980 00:01:00 +0000
2604 Date: Tue, 01 Jan 1980 00:01:00 +0000
2568 From: quux
2605 From: quux
2569 To: bar@xn--nicode-2ya.com
2606 To: bar@xn--nicode-2ya.com
2570
2607
2571 # HG changeset patch
2608 # HG changeset patch
2572 # User test
2609 # User test
2573 # Date 1 0
2610 # Date 1 0
2574 # Thu Jan 01 00:00:01 1970 +0000
2611 # Thu Jan 01 00:00:01 1970 +0000
2575 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
2612 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
2576 # Parent 0000000000000000000000000000000000000000
2613 # Parent 0000000000000000000000000000000000000000
2577 a
2614 a
2578
2615
2579 diff -r 000000000000 -r 8580ff50825a a
2616 diff -r 000000000000 -r 8580ff50825a a
2580 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2617 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2581 +++ b/a Thu Jan 01 00:00:01 1970 +0000
2618 +++ b/a Thu Jan 01 00:00:01 1970 +0000
2582 @@ -0,0 +1,1 @@
2619 @@ -0,0 +1,1 @@
2583 +a
2620 +a
2584
2621
2585
2622
2586
2623
2587 test outgoing:
2624 test outgoing:
2588 $ hg up 1
2625 $ hg up 1
2589 0 files updated, 0 files merged, 6 files removed, 0 files unresolved
2626 0 files updated, 0 files merged, 6 files removed, 0 files unresolved
2590
2627
2591 $ hg branch test
2628 $ hg branch test
2592 marked working directory as branch test
2629 marked working directory as branch test
2593 (branches are permanent and global, did you want a bookmark?)
2630 (branches are permanent and global, did you want a bookmark?)
2594
2631
2595 $ echo d > d
2632 $ echo d > d
2596 $ hg add d
2633 $ hg add d
2597 $ hg ci -md -d '4 0'
2634 $ hg ci -md -d '4 0'
2598 $ echo d >> d
2635 $ echo d >> d
2599 $ hg ci -mdd -d '5 0'
2636 $ hg ci -mdd -d '5 0'
2600 $ hg log -G --template "{rev}:{node|short} {desc|firstline}\n"
2637 $ hg log -G --template "{rev}:{node|short} {desc|firstline}\n"
2601 @ 10:3b6f1ec9dde9 dd
2638 @ 10:3b6f1ec9dde9 dd
2602 |
2639 |
2603 o 9:2f9fa9b998c5 d
2640 o 9:2f9fa9b998c5 d
2604 |
2641 |
2605 | o 8:9cea7492c36b Added tag two, two.diff for changeset ff2c9fa2018b
2642 | o 8:9cea7492c36b Added tag two, two.diff for changeset ff2c9fa2018b
2606 | |
2643 | |
2607 | o 7:3b775b32716d Added tag one, one.patch for changeset 97d72e5f12c7
2644 | o 7:3b775b32716d Added tag one, one.patch for changeset 97d72e5f12c7
2608 | |
2645 | |
2609 | o 6:c41d7353114c Added tag zero, zero.foo for changeset 8580ff50825a
2646 | o 6:c41d7353114c Added tag zero, zero.foo for changeset 8580ff50825a
2610 | |
2647 | |
2611 | o 5:4d6f44f466c9 isolatin 8-bit encoding
2648 | o 5:4d6f44f466c9 isolatin 8-bit encoding
2612 | |
2649 | |
2613 | o 4:0c7b871cb86b long line
2650 | o 4:0c7b871cb86b long line
2614 | |
2651 | |
2615 | o 3:f81ef9782946 \xe7a (esc)
2652 | o 3:f81ef9782946 \xe7a (esc)
2616 | |
2653 | |
2617 | o 2:ff2c9fa2018b c
2654 | o 2:ff2c9fa2018b c
2618 |/
2655 |/
2619 o 1:97d72e5f12c7 b
2656 o 1:97d72e5f12c7 b
2620 |
2657 |
2621 o 0:8580ff50825a a
2658 o 0:8580ff50825a a
2622
2659
2623 $ hg phase --force --secret -r 10
2660 $ hg phase --force --secret -r 10
2624
2661
2625 Test without revisions specified
2662 Test without revisions specified
2626 $ hg email --date '1980-1-1 0:1' -n -o -t foo
2663 $ hg email --date '1980-1-1 0:1' -n -o -t foo
2627 comparing with $TESTTMP/t
2664 comparing with $TESTTMP/t
2628 From [test]: test
2665 From [test]: test
2629 this patch series consists of 1 patches.
2666 this patch series consists of 1 patches.
2630
2667
2631 Cc:
2668 Cc:
2632
2669
2633 displaying [PATCH] d ...
2670 displaying [PATCH] d ...
2634 MIME-Version: 1.0
2671 MIME-Version: 1.0
2635 Content-Type: text/plain; charset="us-ascii"
2672 Content-Type: text/plain; charset="us-ascii"
2636 Content-Transfer-Encoding: 7bit
2673 Content-Transfer-Encoding: 7bit
2637 Subject: [PATCH] d
2674 Subject: [PATCH] d
2638 X-Mercurial-Node: 2f9fa9b998c5fe3ac2bd9a2b14bfcbeecbc7c268
2675 X-Mercurial-Node: 2f9fa9b998c5fe3ac2bd9a2b14bfcbeecbc7c268
2639 X-Mercurial-Series-Index: 1
2676 X-Mercurial-Series-Index: 1
2640 X-Mercurial-Series-Total: 1
2677 X-Mercurial-Series-Total: 1
2641 Message-Id: <2f9fa9b998c5fe3ac2bd.315532860@test-hostname>
2678 Message-Id: <2f9fa9b998c5fe3ac2bd.315532860@test-hostname>
2642 X-Mercurial-Series-Id: <2f9fa9b998c5fe3ac2bd.315532860@test-hostname>
2679 X-Mercurial-Series-Id: <2f9fa9b998c5fe3ac2bd.315532860@test-hostname>
2643 User-Agent: Mercurial-patchbomb/* (glob)
2680 User-Agent: Mercurial-patchbomb/* (glob)
2644 Date: Tue, 01 Jan 1980 00:01:00 +0000
2681 Date: Tue, 01 Jan 1980 00:01:00 +0000
2645 From: test
2682 From: test
2646 To: foo
2683 To: foo
2647
2684
2648 # HG changeset patch
2685 # HG changeset patch
2649 # User test
2686 # User test
2650 # Date 4 0
2687 # Date 4 0
2651 # Thu Jan 01 00:00:04 1970 +0000
2688 # Thu Jan 01 00:00:04 1970 +0000
2652 # Branch test
2689 # Branch test
2653 # Node ID 2f9fa9b998c5fe3ac2bd9a2b14bfcbeecbc7c268
2690 # Node ID 2f9fa9b998c5fe3ac2bd9a2b14bfcbeecbc7c268
2654 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2691 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2655 d
2692 d
2656
2693
2657 diff -r 97d72e5f12c7 -r 2f9fa9b998c5 d
2694 diff -r 97d72e5f12c7 -r 2f9fa9b998c5 d
2658 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2695 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2659 +++ b/d Thu Jan 01 00:00:04 1970 +0000
2696 +++ b/d Thu Jan 01 00:00:04 1970 +0000
2660 @@ -0,0 +1,1 @@
2697 @@ -0,0 +1,1 @@
2661 +d
2698 +d
2662
2699
2663 $ hg email --date '1980-1-1 0:1' -n -t foo -s test -o ../t -r 'rev(10) or rev(6)'
2700 $ hg email --date '1980-1-1 0:1' -n -t foo -s test -o ../t -r 'rev(10) or rev(6)'
2664 comparing with ../t
2701 comparing with ../t
2665 From [test]: test
2702 From [test]: test
2666 this patch series consists of 6 patches.
2703 this patch series consists of 6 patches.
2667
2704
2668
2705
2669 Write the introductory message for the patch series.
2706 Write the introductory message for the patch series.
2670
2707
2671 Cc:
2708 Cc:
2672
2709
2673 displaying [PATCH 0 of 6] test ...
2710 displaying [PATCH 0 of 6] test ...
2674 MIME-Version: 1.0
2711 MIME-Version: 1.0
2675 Content-Type: text/plain; charset="us-ascii"
2712 Content-Type: text/plain; charset="us-ascii"
2676 Content-Transfer-Encoding: 7bit
2713 Content-Transfer-Encoding: 7bit
2677 Subject: [PATCH 0 of 6] test
2714 Subject: [PATCH 0 of 6] test
2678 Message-Id: <patchbomb.315532860@test-hostname>
2715 Message-Id: <patchbomb.315532860@test-hostname>
2679 User-Agent: Mercurial-patchbomb/* (glob)
2716 User-Agent: Mercurial-patchbomb/* (glob)
2680 Date: Tue, 01 Jan 1980 00:01:00 +0000
2717 Date: Tue, 01 Jan 1980 00:01:00 +0000
2681 From: test
2718 From: test
2682 To: foo
2719 To: foo
2683
2720
2684
2721
2685 displaying [PATCH 1 of 6] c ...
2722 displaying [PATCH 1 of 6] c ...
2686 MIME-Version: 1.0
2723 MIME-Version: 1.0
2687 Content-Type: text/plain; charset="us-ascii"
2724 Content-Type: text/plain; charset="us-ascii"
2688 Content-Transfer-Encoding: 7bit
2725 Content-Transfer-Encoding: 7bit
2689 Subject: [PATCH 1 of 6] c
2726 Subject: [PATCH 1 of 6] c
2690 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
2727 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
2691 X-Mercurial-Series-Index: 1
2728 X-Mercurial-Series-Index: 1
2692 X-Mercurial-Series-Total: 6
2729 X-Mercurial-Series-Total: 6
2693 Message-Id: <ff2c9fa2018b15fa74b3.315532861@test-hostname>
2730 Message-Id: <ff2c9fa2018b15fa74b3.315532861@test-hostname>
2694 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.315532861@test-hostname>
2731 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.315532861@test-hostname>
2695 In-Reply-To: <patchbomb.315532860@test-hostname>
2732 In-Reply-To: <patchbomb.315532860@test-hostname>
2696 References: <patchbomb.315532860@test-hostname>
2733 References: <patchbomb.315532860@test-hostname>
2697 User-Agent: Mercurial-patchbomb/* (glob)
2734 User-Agent: Mercurial-patchbomb/* (glob)
2698 Date: Tue, 01 Jan 1980 00:01:01 +0000
2735 Date: Tue, 01 Jan 1980 00:01:01 +0000
2699 From: test
2736 From: test
2700 To: foo
2737 To: foo
2701
2738
2702 # HG changeset patch
2739 # HG changeset patch
2703 # User test
2740 # User test
2704 # Date 3 0
2741 # Date 3 0
2705 # Thu Jan 01 00:00:03 1970 +0000
2742 # Thu Jan 01 00:00:03 1970 +0000
2706 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
2743 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
2707 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2744 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2708 c
2745 c
2709
2746
2710 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
2747 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
2711 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2748 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2712 +++ b/c Thu Jan 01 00:00:03 1970 +0000
2749 +++ b/c Thu Jan 01 00:00:03 1970 +0000
2713 @@ -0,0 +1,1 @@
2750 @@ -0,0 +1,1 @@
2714 +c
2751 +c
2715
2752
2716 displaying [PATCH 2 of 6] \xe7a ... (esc)
2753 displaying [PATCH 2 of 6] \xe7a ... (esc)
2717 MIME-Version: 1.0
2754 MIME-Version: 1.0
2718 Content-Type: text/plain; charset="iso-8859-1"
2755 Content-Type: text/plain; charset="iso-8859-1"
2719 Content-Transfer-Encoding: quoted-printable
2756 Content-Transfer-Encoding: quoted-printable
2720 Subject: =?utf-8?b?W1BBVENIIDIgb2YgNl0gw6dh?= (py3 !)
2757 Subject: =?utf-8?b?W1BBVENIIDIgb2YgNl0gw6dh?= (py3 !)
2721 X-Mercurial-Node: f81ef97829467e868fc405fccbcfa66217e4d3e6
2758 X-Mercurial-Node: f81ef97829467e868fc405fccbcfa66217e4d3e6
2722 X-Mercurial-Series-Index: 2
2759 X-Mercurial-Series-Index: 2
2723 X-Mercurial-Series-Total: 6
2760 X-Mercurial-Series-Total: 6
2724 Message-Id: <f81ef97829467e868fc4.315532862@test-hostname>
2761 Message-Id: <f81ef97829467e868fc4.315532862@test-hostname>
2725 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.315532861@test-hostname>
2762 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.315532861@test-hostname>
2726 In-Reply-To: <patchbomb.315532860@test-hostname>
2763 In-Reply-To: <patchbomb.315532860@test-hostname>
2727 References: <patchbomb.315532860@test-hostname>
2764 References: <patchbomb.315532860@test-hostname>
2728 User-Agent: Mercurial-patchbomb/* (glob)
2765 User-Agent: Mercurial-patchbomb/* (glob)
2729 Date: Tue, 01 Jan 1980 00:01:02 +0000
2766 Date: Tue, 01 Jan 1980 00:01:02 +0000
2730 From: test
2767 From: test
2731 To: foo
2768 To: foo
2732
2769
2733 # HG changeset patch
2770 # HG changeset patch
2734 # User test
2771 # User test
2735 # Date 4 0
2772 # Date 4 0
2736 # Thu Jan 01 00:00:04 1970 +0000
2773 # Thu Jan 01 00:00:04 1970 +0000
2737 # Node ID f81ef97829467e868fc405fccbcfa66217e4d3e6
2774 # Node ID f81ef97829467e868fc405fccbcfa66217e4d3e6
2738 # Parent ff2c9fa2018b15fa74b33363bda9527323e2a99f
2775 # Parent ff2c9fa2018b15fa74b33363bda9527323e2a99f
2739 =E7a
2776 =E7a
2740
2777
2741 diff -r ff2c9fa2018b -r f81ef9782946 description
2778 diff -r ff2c9fa2018b -r f81ef9782946 description
2742 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2779 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2743 +++ b/description Thu Jan 01 00:00:04 1970 +0000
2780 +++ b/description Thu Jan 01 00:00:04 1970 +0000
2744 @@ -0,0 +1,3 @@
2781 @@ -0,0 +1,3 @@
2745 +a multiline
2782 +a multiline
2746 +
2783 +
2747 +description
2784 +description
2748 diff -r ff2c9fa2018b -r f81ef9782946 utf
2785 diff -r ff2c9fa2018b -r f81ef9782946 utf
2749 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2786 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2750 +++ b/utf Thu Jan 01 00:00:04 1970 +0000
2787 +++ b/utf Thu Jan 01 00:00:04 1970 +0000
2751 @@ -0,0 +1,1 @@
2788 @@ -0,0 +1,1 @@
2752 +h=C3=B6mma!
2789 +h=C3=B6mma!
2753
2790
2754 displaying [PATCH 3 of 6] long line ...
2791 displaying [PATCH 3 of 6] long line ...
2755 MIME-Version: 1.0
2792 MIME-Version: 1.0
2756 Content-Type: text/plain; charset="us-ascii"
2793 Content-Type: text/plain; charset="us-ascii"
2757 Content-Transfer-Encoding: quoted-printable
2794 Content-Transfer-Encoding: quoted-printable
2758 Subject: [PATCH 3 of 6] long line
2795 Subject: [PATCH 3 of 6] long line
2759 X-Mercurial-Node: 0c7b871cb86b61a1c07e244393603c361e4a178d
2796 X-Mercurial-Node: 0c7b871cb86b61a1c07e244393603c361e4a178d
2760 X-Mercurial-Series-Index: 3
2797 X-Mercurial-Series-Index: 3
2761 X-Mercurial-Series-Total: 6
2798 X-Mercurial-Series-Total: 6
2762 Message-Id: <0c7b871cb86b61a1c07e.315532863@test-hostname>
2799 Message-Id: <0c7b871cb86b61a1c07e.315532863@test-hostname>
2763 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.315532861@test-hostname>
2800 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.315532861@test-hostname>
2764 In-Reply-To: <patchbomb.315532860@test-hostname>
2801 In-Reply-To: <patchbomb.315532860@test-hostname>
2765 References: <patchbomb.315532860@test-hostname>
2802 References: <patchbomb.315532860@test-hostname>
2766 User-Agent: Mercurial-patchbomb/* (glob)
2803 User-Agent: Mercurial-patchbomb/* (glob)
2767 Date: Tue, 01 Jan 1980 00:01:03 +0000
2804 Date: Tue, 01 Jan 1980 00:01:03 +0000
2768 From: test
2805 From: test
2769 To: foo
2806 To: foo
2770
2807
2771 # HG changeset patch
2808 # HG changeset patch
2772 # User test
2809 # User test
2773 # Date 4 0
2810 # Date 4 0
2774 # Thu Jan 01 00:00:04 1970 +0000
2811 # Thu Jan 01 00:00:04 1970 +0000
2775 # Node ID 0c7b871cb86b61a1c07e244393603c361e4a178d
2812 # Node ID 0c7b871cb86b61a1c07e244393603c361e4a178d
2776 # Parent f81ef97829467e868fc405fccbcfa66217e4d3e6
2813 # Parent f81ef97829467e868fc405fccbcfa66217e4d3e6
2777 long line
2814 long line
2778
2815
2779 diff -r f81ef9782946 -r 0c7b871cb86b long
2816 diff -r f81ef9782946 -r 0c7b871cb86b long
2780 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2817 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2781 +++ b/long Thu Jan 01 00:00:04 1970 +0000
2818 +++ b/long Thu Jan 01 00:00:04 1970 +0000
2782 @@ -0,0 +1,4 @@
2819 @@ -0,0 +1,4 @@
2783 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2820 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2784 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2821 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2785 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2822 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2786 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2823 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2787 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2824 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2788 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2825 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2789 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2826 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2790 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2827 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2791 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2828 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2792 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2829 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2793 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2830 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2794 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2831 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2795 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2832 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
2796 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
2833 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
2797 +foo
2834 +foo
2798 +
2835 +
2799 +bar
2836 +bar
2800
2837
2801 displaying [PATCH 4 of 6] isolatin 8-bit encoding ...
2838 displaying [PATCH 4 of 6] isolatin 8-bit encoding ...
2802 MIME-Version: 1.0
2839 MIME-Version: 1.0
2803 Content-Type: text/plain; charset="iso-8859-1"
2840 Content-Type: text/plain; charset="iso-8859-1"
2804 Content-Transfer-Encoding: quoted-printable
2841 Content-Transfer-Encoding: quoted-printable
2805 Subject: [PATCH 4 of 6] isolatin 8-bit encoding
2842 Subject: [PATCH 4 of 6] isolatin 8-bit encoding
2806 X-Mercurial-Node: 4d6f44f466c96d89f2e7e865a70ff41d8b6eee37
2843 X-Mercurial-Node: 4d6f44f466c96d89f2e7e865a70ff41d8b6eee37
2807 X-Mercurial-Series-Index: 4
2844 X-Mercurial-Series-Index: 4
2808 X-Mercurial-Series-Total: 6
2845 X-Mercurial-Series-Total: 6
2809 Message-Id: <4d6f44f466c96d89f2e7.315532864@test-hostname>
2846 Message-Id: <4d6f44f466c96d89f2e7.315532864@test-hostname>
2810 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.315532861@test-hostname>
2847 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.315532861@test-hostname>
2811 In-Reply-To: <patchbomb.315532860@test-hostname>
2848 In-Reply-To: <patchbomb.315532860@test-hostname>
2812 References: <patchbomb.315532860@test-hostname>
2849 References: <patchbomb.315532860@test-hostname>
2813 User-Agent: Mercurial-patchbomb/* (glob)
2850 User-Agent: Mercurial-patchbomb/* (glob)
2814 Date: Tue, 01 Jan 1980 00:01:04 +0000
2851 Date: Tue, 01 Jan 1980 00:01:04 +0000
2815 From: test
2852 From: test
2816 To: foo
2853 To: foo
2817
2854
2818 # HG changeset patch
2855 # HG changeset patch
2819 # User test
2856 # User test
2820 # Date 5 0
2857 # Date 5 0
2821 # Thu Jan 01 00:00:05 1970 +0000
2858 # Thu Jan 01 00:00:05 1970 +0000
2822 # Node ID 4d6f44f466c96d89f2e7e865a70ff41d8b6eee37
2859 # Node ID 4d6f44f466c96d89f2e7e865a70ff41d8b6eee37
2823 # Parent 0c7b871cb86b61a1c07e244393603c361e4a178d
2860 # Parent 0c7b871cb86b61a1c07e244393603c361e4a178d
2824 isolatin 8-bit encoding
2861 isolatin 8-bit encoding
2825
2862
2826 diff -r 0c7b871cb86b -r 4d6f44f466c9 isolatin
2863 diff -r 0c7b871cb86b -r 4d6f44f466c9 isolatin
2827 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2864 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2828 +++ b/isolatin Thu Jan 01 00:00:05 1970 +0000
2865 +++ b/isolatin Thu Jan 01 00:00:05 1970 +0000
2829 @@ -0,0 +1,1 @@
2866 @@ -0,0 +1,1 @@
2830 +h=F6mma!
2867 +h=F6mma!
2831
2868
2832 displaying [PATCH 5 of 6] Added tag zero, zero.foo for changeset 8580ff50825a ...
2869 displaying [PATCH 5 of 6] Added tag zero, zero.foo for changeset 8580ff50825a ...
2833 MIME-Version: 1.0
2870 MIME-Version: 1.0
2834 Content-Type: text/plain; charset="us-ascii"
2871 Content-Type: text/plain; charset="us-ascii"
2835 Content-Transfer-Encoding: 7bit
2872 Content-Transfer-Encoding: 7bit
2836 Subject: [PATCH 5 of 6] Added tag zero, zero.foo for changeset 8580ff50825a
2873 Subject: [PATCH 5 of 6] Added tag zero, zero.foo for changeset 8580ff50825a
2837 X-Mercurial-Node: c41d7353114ccb07a50a822ad5ddf47051c88ec2
2874 X-Mercurial-Node: c41d7353114ccb07a50a822ad5ddf47051c88ec2
2838 X-Mercurial-Series-Index: 5
2875 X-Mercurial-Series-Index: 5
2839 X-Mercurial-Series-Total: 6
2876 X-Mercurial-Series-Total: 6
2840 Message-Id: <c41d7353114ccb07a50a.315532865@test-hostname>
2877 Message-Id: <c41d7353114ccb07a50a.315532865@test-hostname>
2841 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.315532861@test-hostname>
2878 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.315532861@test-hostname>
2842 In-Reply-To: <patchbomb.315532860@test-hostname>
2879 In-Reply-To: <patchbomb.315532860@test-hostname>
2843 References: <patchbomb.315532860@test-hostname>
2880 References: <patchbomb.315532860@test-hostname>
2844 User-Agent: Mercurial-patchbomb/* (glob)
2881 User-Agent: Mercurial-patchbomb/* (glob)
2845 Date: Tue, 01 Jan 1980 00:01:05 +0000
2882 Date: Tue, 01 Jan 1980 00:01:05 +0000
2846 From: test
2883 From: test
2847 To: foo
2884 To: foo
2848
2885
2849 # HG changeset patch
2886 # HG changeset patch
2850 # User test
2887 # User test
2851 # Date 0 0
2888 # Date 0 0
2852 # Thu Jan 01 00:00:00 1970 +0000
2889 # Thu Jan 01 00:00:00 1970 +0000
2853 # Node ID c41d7353114ccb07a50a822ad5ddf47051c88ec2
2890 # Node ID c41d7353114ccb07a50a822ad5ddf47051c88ec2
2854 # Parent 4d6f44f466c96d89f2e7e865a70ff41d8b6eee37
2891 # Parent 4d6f44f466c96d89f2e7e865a70ff41d8b6eee37
2855 Added tag zero, zero.foo for changeset 8580ff50825a
2892 Added tag zero, zero.foo for changeset 8580ff50825a
2856
2893
2857 diff -r 4d6f44f466c9 -r c41d7353114c .hgtags
2894 diff -r 4d6f44f466c9 -r c41d7353114c .hgtags
2858 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2895 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2859 +++ b/.hgtags Thu Jan 01 00:00:00 1970 +0000
2896 +++ b/.hgtags Thu Jan 01 00:00:00 1970 +0000
2860 @@ -0,0 +1,2 @@
2897 @@ -0,0 +1,2 @@
2861 +8580ff50825a50c8f716709acdf8de0deddcd6ab zero
2898 +8580ff50825a50c8f716709acdf8de0deddcd6ab zero
2862 +8580ff50825a50c8f716709acdf8de0deddcd6ab zero.foo
2899 +8580ff50825a50c8f716709acdf8de0deddcd6ab zero.foo
2863
2900
2864 displaying [PATCH 6 of 6] d ...
2901 displaying [PATCH 6 of 6] d ...
2865 MIME-Version: 1.0
2902 MIME-Version: 1.0
2866 Content-Type: text/plain; charset="us-ascii"
2903 Content-Type: text/plain; charset="us-ascii"
2867 Content-Transfer-Encoding: 7bit
2904 Content-Transfer-Encoding: 7bit
2868 Subject: [PATCH 6 of 6] d
2905 Subject: [PATCH 6 of 6] d
2869 X-Mercurial-Node: 2f9fa9b998c5fe3ac2bd9a2b14bfcbeecbc7c268
2906 X-Mercurial-Node: 2f9fa9b998c5fe3ac2bd9a2b14bfcbeecbc7c268
2870 X-Mercurial-Series-Index: 6
2907 X-Mercurial-Series-Index: 6
2871 X-Mercurial-Series-Total: 6
2908 X-Mercurial-Series-Total: 6
2872 Message-Id: <2f9fa9b998c5fe3ac2bd.315532866@test-hostname>
2909 Message-Id: <2f9fa9b998c5fe3ac2bd.315532866@test-hostname>
2873 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.315532861@test-hostname>
2910 X-Mercurial-Series-Id: <ff2c9fa2018b15fa74b3.315532861@test-hostname>
2874 In-Reply-To: <patchbomb.315532860@test-hostname>
2911 In-Reply-To: <patchbomb.315532860@test-hostname>
2875 References: <patchbomb.315532860@test-hostname>
2912 References: <patchbomb.315532860@test-hostname>
2876 User-Agent: Mercurial-patchbomb/* (glob)
2913 User-Agent: Mercurial-patchbomb/* (glob)
2877 Date: Tue, 01 Jan 1980 00:01:06 +0000
2914 Date: Tue, 01 Jan 1980 00:01:06 +0000
2878 From: test
2915 From: test
2879 To: foo
2916 To: foo
2880
2917
2881 # HG changeset patch
2918 # HG changeset patch
2882 # User test
2919 # User test
2883 # Date 4 0
2920 # Date 4 0
2884 # Thu Jan 01 00:00:04 1970 +0000
2921 # Thu Jan 01 00:00:04 1970 +0000
2885 # Branch test
2922 # Branch test
2886 # Node ID 2f9fa9b998c5fe3ac2bd9a2b14bfcbeecbc7c268
2923 # Node ID 2f9fa9b998c5fe3ac2bd9a2b14bfcbeecbc7c268
2887 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2924 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2888 d
2925 d
2889
2926
2890 diff -r 97d72e5f12c7 -r 2f9fa9b998c5 d
2927 diff -r 97d72e5f12c7 -r 2f9fa9b998c5 d
2891 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2928 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2892 +++ b/d Thu Jan 01 00:00:04 1970 +0000
2929 +++ b/d Thu Jan 01 00:00:04 1970 +0000
2893 @@ -0,0 +1,1 @@
2930 @@ -0,0 +1,1 @@
2894 +d
2931 +d
2895
2932
2896
2933
2897 Don't prompt for a CC header.
2934 Don't prompt for a CC header.
2898
2935
2899 $ echo "[email]" >> $HGRCPATH
2936 $ echo "[email]" >> $HGRCPATH
2900 $ echo "cc=" >> $HGRCPATH
2937 $ echo "cc=" >> $HGRCPATH
2901
2938
2902 dest#branch URIs:
2939 dest#branch URIs:
2903 $ hg email --date '1980-1-1 0:1' -n -t foo -s test -o ../t#test
2940 $ hg email --date '1980-1-1 0:1' -n -t foo -s test -o ../t#test
2904 comparing with ../t#test
2941 comparing with ../t#test
2905 From [test]: test
2942 From [test]: test
2906 this patch series consists of 1 patches.
2943 this patch series consists of 1 patches.
2907
2944
2908
2945
2909 displaying [PATCH] test ...
2946 displaying [PATCH] test ...
2910 MIME-Version: 1.0
2947 MIME-Version: 1.0
2911 Content-Type: text/plain; charset="us-ascii"
2948 Content-Type: text/plain; charset="us-ascii"
2912 Content-Transfer-Encoding: 7bit
2949 Content-Transfer-Encoding: 7bit
2913 Subject: [PATCH] test
2950 Subject: [PATCH] test
2914 X-Mercurial-Node: 2f9fa9b998c5fe3ac2bd9a2b14bfcbeecbc7c268
2951 X-Mercurial-Node: 2f9fa9b998c5fe3ac2bd9a2b14bfcbeecbc7c268
2915 X-Mercurial-Series-Index: 1
2952 X-Mercurial-Series-Index: 1
2916 X-Mercurial-Series-Total: 1
2953 X-Mercurial-Series-Total: 1
2917 Message-Id: <2f9fa9b998c5fe3ac2bd.315532860@test-hostname>
2954 Message-Id: <2f9fa9b998c5fe3ac2bd.315532860@test-hostname>
2918 X-Mercurial-Series-Id: <2f9fa9b998c5fe3ac2bd.315532860@test-hostname>
2955 X-Mercurial-Series-Id: <2f9fa9b998c5fe3ac2bd.315532860@test-hostname>
2919 User-Agent: Mercurial-patchbomb/* (glob)
2956 User-Agent: Mercurial-patchbomb/* (glob)
2920 Date: Tue, 01 Jan 1980 00:01:00 +0000
2957 Date: Tue, 01 Jan 1980 00:01:00 +0000
2921 From: test
2958 From: test
2922 To: foo
2959 To: foo
2923
2960
2924 # HG changeset patch
2961 # HG changeset patch
2925 # User test
2962 # User test
2926 # Date 4 0
2963 # Date 4 0
2927 # Thu Jan 01 00:00:04 1970 +0000
2964 # Thu Jan 01 00:00:04 1970 +0000
2928 # Branch test
2965 # Branch test
2929 # Node ID 2f9fa9b998c5fe3ac2bd9a2b14bfcbeecbc7c268
2966 # Node ID 2f9fa9b998c5fe3ac2bd9a2b14bfcbeecbc7c268
2930 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2967 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2931 d
2968 d
2932
2969
2933 diff -r 97d72e5f12c7 -r 2f9fa9b998c5 d
2970 diff -r 97d72e5f12c7 -r 2f9fa9b998c5 d
2934 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2971 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2935 +++ b/d Thu Jan 01 00:00:04 1970 +0000
2972 +++ b/d Thu Jan 01 00:00:04 1970 +0000
2936 @@ -0,0 +1,1 @@
2973 @@ -0,0 +1,1 @@
2937 +d
2974 +d
2938
2975
2939 #if no-windows
2976 #if no-windows
2940
2977
2941 Set up a fake sendmail program
2978 Set up a fake sendmail program
2942
2979
2943 $ cat > pretendmail.sh << 'EOF'
2980 $ cat > pretendmail.sh << 'EOF'
2944 > #!/bin/sh
2981 > #!/bin/sh
2945 > echo "$@"
2982 > echo "$@"
2946 > cat
2983 > cat
2947 > EOF
2984 > EOF
2948 $ chmod +x pretendmail.sh
2985 $ chmod +x pretendmail.sh
2949
2986
2950 $ echo '[email]' >> $HGRCPATH
2987 $ echo '[email]' >> $HGRCPATH
2951 $ echo "method=`pwd`/pretendmail.sh" >> $HGRCPATH
2988 $ echo "method=`pwd`/pretendmail.sh" >> $HGRCPATH
2952
2989
2953 Test introduction configuration
2990 Test introduction configuration
2954 =================================
2991 =================================
2955
2992
2956 $ echo '[patchbomb]' >> $HGRCPATH
2993 $ echo '[patchbomb]' >> $HGRCPATH
2957
2994
2958 "auto" setting
2995 "auto" setting
2959 ----------------
2996 ----------------
2960
2997
2961 $ echo 'intro=auto' >> $HGRCPATH
2998 $ echo 'intro=auto' >> $HGRCPATH
2962
2999
2963 single rev
3000 single rev
2964
3001
2965 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '10' | grep "Write the introductory message for the patch series."
3002 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '10' | grep "Write the introductory message for the patch series."
2966 [1]
3003 [1]
2967
3004
2968 single rev + flag
3005 single rev + flag
2969
3006
2970 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '10' --intro | grep "Write the introductory message for the patch series."
3007 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '10' --intro | grep "Write the introductory message for the patch series."
2971 Write the introductory message for the patch series.
3008 Write the introductory message for the patch series.
2972
3009
2973
3010
2974 Multi rev
3011 Multi rev
2975
3012
2976 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '9::' | grep "Write the introductory message for the patch series."
3013 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '9::' | grep "Write the introductory message for the patch series."
2977 Write the introductory message for the patch series.
3014 Write the introductory message for the patch series.
2978
3015
2979 "never" setting
3016 "never" setting
2980 -----------------
3017 -----------------
2981
3018
2982 $ echo 'intro=never' >> $HGRCPATH
3019 $ echo 'intro=never' >> $HGRCPATH
2983
3020
2984 single rev
3021 single rev
2985
3022
2986 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '10' | grep "Write the introductory message for the patch series."
3023 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '10' | grep "Write the introductory message for the patch series."
2987 [1]
3024 [1]
2988
3025
2989 single rev + flag
3026 single rev + flag
2990
3027
2991 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '10' --intro | grep "Write the introductory message for the patch series."
3028 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '10' --intro | grep "Write the introductory message for the patch series."
2992 Write the introductory message for the patch series.
3029 Write the introductory message for the patch series.
2993
3030
2994
3031
2995 Multi rev
3032 Multi rev
2996
3033
2997 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '9::' | grep "Write the introductory message for the patch series."
3034 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '9::' | grep "Write the introductory message for the patch series."
2998 [1]
3035 [1]
2999
3036
3000 Multi rev + flag
3037 Multi rev + flag
3001
3038
3002 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '9::' --intro | grep "Write the introductory message for the patch series."
3039 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '9::' --intro | grep "Write the introductory message for the patch series."
3003 Write the introductory message for the patch series.
3040 Write the introductory message for the patch series.
3004
3041
3005 "always" setting
3042 "always" setting
3006 -----------------
3043 -----------------
3007
3044
3008 $ echo 'intro=always' >> $HGRCPATH
3045 $ echo 'intro=always' >> $HGRCPATH
3009
3046
3010 single rev
3047 single rev
3011
3048
3012 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '10' | grep "Write the introductory message for the patch series."
3049 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '10' | grep "Write the introductory message for the patch series."
3013 Write the introductory message for the patch series.
3050 Write the introductory message for the patch series.
3014
3051
3015 single rev + flag
3052 single rev + flag
3016
3053
3017 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '10' --intro | grep "Write the introductory message for the patch series."
3054 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '10' --intro | grep "Write the introductory message for the patch series."
3018 Write the introductory message for the patch series.
3055 Write the introductory message for the patch series.
3019
3056
3020
3057
3021 Multi rev
3058 Multi rev
3022
3059
3023 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '9::' | grep "Write the introductory message for the patch series."
3060 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '9::' | grep "Write the introductory message for the patch series."
3024 Write the introductory message for the patch series.
3061 Write the introductory message for the patch series.
3025
3062
3026 Multi rev + flag
3063 Multi rev + flag
3027
3064
3028 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '9::' --intro | grep "Write the introductory message for the patch series."
3065 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '9::' --intro | grep "Write the introductory message for the patch series."
3029 Write the introductory message for the patch series.
3066 Write the introductory message for the patch series.
3030
3067
3031 bad value setting
3068 bad value setting
3032 -----------------
3069 -----------------
3033
3070
3034 $ echo 'intro=oliviawearaclownnose' >> $HGRCPATH
3071 $ echo 'intro=oliviawearaclownnose' >> $HGRCPATH
3035
3072
3036 single rev
3073 single rev
3037
3074
3038 $ hg email --date '1980-1-1 0:1' -v -t foo -s test -r '10'
3075 $ hg email --date '1980-1-1 0:1' -v -t foo -s test -r '10'
3039 From [test]: test
3076 From [test]: test
3040 this patch series consists of 1 patches.
3077 this patch series consists of 1 patches.
3041
3078
3042 warning: invalid patchbomb.intro value "oliviawearaclownnose"
3079 warning: invalid patchbomb.intro value "oliviawearaclownnose"
3043 (should be one of always, never, auto)
3080 (should be one of always, never, auto)
3044 -f test foo
3081 -f test foo
3045 MIME-Version: 1.0
3082 MIME-Version: 1.0
3046 Content-Type: text/plain; charset="us-ascii"
3083 Content-Type: text/plain; charset="us-ascii"
3047 Content-Transfer-Encoding: 7bit
3084 Content-Transfer-Encoding: 7bit
3048 Subject: [PATCH] test
3085 Subject: [PATCH] test
3049 X-Mercurial-Node: 3b6f1ec9dde933a40a115a7990f8b320477231af
3086 X-Mercurial-Node: 3b6f1ec9dde933a40a115a7990f8b320477231af
3050 X-Mercurial-Series-Index: 1
3087 X-Mercurial-Series-Index: 1
3051 X-Mercurial-Series-Total: 1
3088 X-Mercurial-Series-Total: 1
3052 Message-Id: <3b6f1ec9dde933a40a11*> (glob)
3089 Message-Id: <3b6f1ec9dde933a40a11*> (glob)
3053 X-Mercurial-Series-Id: <3b6f1ec9dde933a40a11.*> (glob)
3090 X-Mercurial-Series-Id: <3b6f1ec9dde933a40a11.*> (glob)
3054 User-Agent: Mercurial-patchbomb/* (glob)
3091 User-Agent: Mercurial-patchbomb/* (glob)
3055 Date: Tue, 01 Jan 1980 00:01:00 +0000
3092 Date: Tue, 01 Jan 1980 00:01:00 +0000
3056 From: test
3093 From: test
3057 To: foo
3094 To: foo
3058
3095
3059 # HG changeset patch
3096 # HG changeset patch
3060 # User test
3097 # User test
3061 # Date 5 0
3098 # Date 5 0
3062 # Thu Jan 01 00:00:05 1970 +0000
3099 # Thu Jan 01 00:00:05 1970 +0000
3063 # Branch test
3100 # Branch test
3064 # Node ID 3b6f1ec9dde933a40a115a7990f8b320477231af
3101 # Node ID 3b6f1ec9dde933a40a115a7990f8b320477231af
3065 # Parent 2f9fa9b998c5fe3ac2bd9a2b14bfcbeecbc7c268
3102 # Parent 2f9fa9b998c5fe3ac2bd9a2b14bfcbeecbc7c268
3066 dd
3103 dd
3067
3104
3068 diff -r 2f9fa9b998c5 -r 3b6f1ec9dde9 d
3105 diff -r 2f9fa9b998c5 -r 3b6f1ec9dde9 d
3069 --- a/d Thu Jan 01 00:00:04 1970 +0000
3106 --- a/d Thu Jan 01 00:00:04 1970 +0000
3070 +++ b/d Thu Jan 01 00:00:05 1970 +0000
3107 +++ b/d Thu Jan 01 00:00:05 1970 +0000
3071 @@ -1,1 +1,2 @@
3108 @@ -1,1 +1,2 @@
3072 d
3109 d
3073 +d
3110 +d
3074
3111
3075 sending [PATCH] test ...
3112 sending [PATCH] test ...
3076 sending mail: $TESTTMP/t2/pretendmail.sh -f test foo
3113 sending mail: $TESTTMP/t2/pretendmail.sh -f test foo
3077
3114
3078 Shell characters in addresses
3115 Shell characters in addresses
3079
3116
3080 $ hg email --date '1980-1-1 0:1' -v -t '~foo/bar@example.com' -f 'me*@example.com' -r '10'
3117 $ hg email --date '1980-1-1 0:1' -v -t '~foo/bar@example.com' -f 'me*@example.com' -r '10'
3081 this patch series consists of 1 patches.
3118 this patch series consists of 1 patches.
3082
3119
3083 warning: invalid patchbomb.intro value "oliviawearaclownnose"
3120 warning: invalid patchbomb.intro value "oliviawearaclownnose"
3084 (should be one of always, never, auto)
3121 (should be one of always, never, auto)
3085 -f me*@example.com ~foo/bar@example.com
3122 -f me*@example.com ~foo/bar@example.com
3086 MIME-Version: 1.0
3123 MIME-Version: 1.0
3087 Content-Type: text/plain; charset="us-ascii"
3124 Content-Type: text/plain; charset="us-ascii"
3088 Content-Transfer-Encoding: 7bit
3125 Content-Transfer-Encoding: 7bit
3089 Subject: [PATCH] dd
3126 Subject: [PATCH] dd
3090 X-Mercurial-Node: 3b6f1ec9dde933a40a115a7990f8b320477231af
3127 X-Mercurial-Node: 3b6f1ec9dde933a40a115a7990f8b320477231af
3091 X-Mercurial-Series-Index: 1
3128 X-Mercurial-Series-Index: 1
3092 X-Mercurial-Series-Total: 1
3129 X-Mercurial-Series-Total: 1
3093 Message-Id: <3b6f1ec9dde933a40a11.315532860@test-hostname>
3130 Message-Id: <3b6f1ec9dde933a40a11.315532860@test-hostname>
3094 X-Mercurial-Series-Id: <3b6f1ec9dde933a40a11.315532860@test-hostname>
3131 X-Mercurial-Series-Id: <3b6f1ec9dde933a40a11.315532860@test-hostname>
3095 User-Agent: Mercurial-patchbomb/* (glob)
3132 User-Agent: Mercurial-patchbomb/* (glob)
3096 Date: Tue, 01 Jan 1980 00:01:00 +0000
3133 Date: Tue, 01 Jan 1980 00:01:00 +0000
3097 From: me*@example.com
3134 From: me*@example.com
3098 To: ~foo/bar@example.com
3135 To: ~foo/bar@example.com
3099
3136
3100 # HG changeset patch
3137 # HG changeset patch
3101 # User test
3138 # User test
3102 # Date 5 0
3139 # Date 5 0
3103 # Thu Jan 01 00:00:05 1970 +0000
3140 # Thu Jan 01 00:00:05 1970 +0000
3104 # Branch test
3141 # Branch test
3105 # Node ID 3b6f1ec9dde933a40a115a7990f8b320477231af
3142 # Node ID 3b6f1ec9dde933a40a115a7990f8b320477231af
3106 # Parent 2f9fa9b998c5fe3ac2bd9a2b14bfcbeecbc7c268
3143 # Parent 2f9fa9b998c5fe3ac2bd9a2b14bfcbeecbc7c268
3107 dd
3144 dd
3108
3145
3109 diff -r 2f9fa9b998c5 -r 3b6f1ec9dde9 d
3146 diff -r 2f9fa9b998c5 -r 3b6f1ec9dde9 d
3110 --- a/d Thu Jan 01 00:00:04 1970 +0000
3147 --- a/d Thu Jan 01 00:00:04 1970 +0000
3111 +++ b/d Thu Jan 01 00:00:05 1970 +0000
3148 +++ b/d Thu Jan 01 00:00:05 1970 +0000
3112 @@ -1,1 +1,2 @@
3149 @@ -1,1 +1,2 @@
3113 d
3150 d
3114 +d
3151 +d
3115
3152
3116 sending [PATCH] dd ...
3153 sending [PATCH] dd ...
3117 sending mail: $TESTTMP/t2/pretendmail.sh -f 'me*@example.com' '~foo/bar@example.com'
3154 sending mail: $TESTTMP/t2/pretendmail.sh -f 'me*@example.com' '~foo/bar@example.com'
3118
3155
3119 Test pull url header
3156 Test pull url header
3120 =================================
3157 =================================
3121
3158
3122 basic version
3159 basic version
3123
3160
3124 $ echo 'intro=auto' >> $HGRCPATH
3161 $ echo 'intro=auto' >> $HGRCPATH
3125 $ echo "publicurl=$TESTTMP/t2" >> $HGRCPATH
3162 $ echo "publicurl=$TESTTMP/t2" >> $HGRCPATH
3126 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '10' | grep '^#'
3163 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '10' | grep '^#'
3127 abort: public url $TESTTMP/t2 is missing 3b6f1ec9dde9
3164 abort: public url $TESTTMP/t2 is missing 3b6f1ec9dde9
3128 (use 'hg push $TESTTMP/t2 -r 3b6f1ec9dde9')
3165 (use 'hg push $TESTTMP/t2 -r 3b6f1ec9dde9')
3129 [1]
3166 [1]
3130
3167
3131 public missing
3168 public missing
3132
3169
3133 $ echo 'publicurl=$TESTTMP/missing' >> $HGRCPATH
3170 $ echo 'publicurl=$TESTTMP/missing' >> $HGRCPATH
3134 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '10'
3171 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '10'
3135 unable to access public repo: $TESTTMP/missing
3172 unable to access public repo: $TESTTMP/missing
3136 abort: repository $TESTTMP/missing not found
3173 abort: repository $TESTTMP/missing not found
3137 [255]
3174 [255]
3138
3175
3139 node missing at public
3176 node missing at public
3140
3177
3141 $ hg clone -r '9' . ../t3
3178 $ hg clone -r '9' . ../t3
3142 adding changesets
3179 adding changesets
3143 adding manifests
3180 adding manifests
3144 adding file changes
3181 adding file changes
3145 added 3 changesets with 3 changes to 3 files
3182 added 3 changesets with 3 changes to 3 files
3146 new changesets 8580ff50825a:2f9fa9b998c5
3183 new changesets 8580ff50825a:2f9fa9b998c5
3147 updating to branch test
3184 updating to branch test
3148 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
3185 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
3149 $ echo 'publicurl=$TESTTMP/t3' >> $HGRCPATH
3186 $ echo 'publicurl=$TESTTMP/t3' >> $HGRCPATH
3150 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '10'
3187 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '10'
3151 abort: public url $TESTTMP/t3 is missing 3b6f1ec9dde9
3188 abort: public url $TESTTMP/t3 is missing 3b6f1ec9dde9
3152 (use 'hg push $TESTTMP/t3 -r 3b6f1ec9dde9')
3189 (use 'hg push $TESTTMP/t3 -r 3b6f1ec9dde9')
3153 [255]
3190 [255]
3154
3191
3155 multiple heads are missing at public
3192 multiple heads are missing at public
3156
3193
3157 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '2+10'
3194 $ hg email --date '1980-1-1 0:1' -t foo -s test -r '2+10'
3158 abort: public "$TESTTMP/t3" is missing ff2c9fa2018b and 1 others
3195 abort: public "$TESTTMP/t3" is missing ff2c9fa2018b and 1 others
3159 (use 'hg push $TESTTMP/t3 -r ff2c9fa2018b -r 3b6f1ec9dde9')
3196 (use 'hg push $TESTTMP/t3 -r ff2c9fa2018b -r 3b6f1ec9dde9')
3160 [255]
3197 [255]
3161
3198
3162 #endif
3199 #endif
General Comments 0
You need to be logged in to leave comments. Login now