##// END OF EJS Templates
patchbomb: add --confirm option to show series details and ask for confirmation...
Christian Ebert -
r12201:5bfa4565 default
parent child Browse files
Show More
@@ -1,553 +1,554 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 Matt Mackall <mpm@selenic.com> and others
3 # Copyright 2005-2009 Matt Mackall <mpm@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 With the -d/--diffstat option, you will be presented with a final
25 With the -d/--diffstat or -c/--confirm options, you will be presented
26 summary of all messages and asked for confirmation before the messages
26 with a final summary of all messages and asked for confirmation before
27 are sent.
27 the messages are sent.
28
28
29 To configure other defaults, add a section like this to your hgrc
29 To configure other defaults, add a section like this to your hgrc
30 file::
30 file::
31
31
32 [email]
32 [email]
33 from = My Name <my@email>
33 from = My Name <my@email>
34 to = recipient1, recipient2, ...
34 to = recipient1, recipient2, ...
35 cc = cc1, cc2, ...
35 cc = cc1, cc2, ...
36 bcc = bcc1, bcc2, ...
36 bcc = bcc1, bcc2, ...
37 reply-to = address1, address2, ...
37 reply-to = address1, address2, ...
38
38
39 Use ``[patchbomb]`` as configuration section name if you need to
39 Use ``[patchbomb]`` as configuration section name if you need to
40 override global ``[email]`` address settings.
40 override global ``[email]`` address settings.
41
41
42 Then you can use the :hg:`email` command to mail a series of
42 Then you can use the :hg:`email` command to mail a series of
43 changesets as a patchbomb.
43 changesets as a patchbomb.
44
44
45 To avoid sending patches prematurely, it is a good idea to first run
45 To avoid sending patches prematurely, it is a good idea to first run
46 the :hg:`email` command with the "-n" option (test only). You will be
46 the :hg:`email` command with the "-n" option (test only). You will be
47 prompted for an email recipient address, a subject and an introductory
47 prompted for an email recipient address, a subject and an introductory
48 message describing the patches of your patchbomb. Then when all is
48 message describing the patches of your patchbomb. Then when all is
49 done, patchbomb messages are displayed. If the PAGER environment
49 done, patchbomb messages are displayed. If the PAGER environment
50 variable is set, your pager will be fired up once for each patchbomb
50 variable is set, your pager will be fired up once for each patchbomb
51 message, so you can verify everything is alright.
51 message, so you can verify everything is alright.
52
52
53 The -m/--mbox option is also very useful. Instead of previewing each
53 The -m/--mbox option is also very useful. Instead of previewing each
54 patchbomb message in a pager or sending the messages directly, it will
54 patchbomb message in a pager or sending the messages directly, it will
55 create a UNIX mailbox file with the patch emails. This mailbox file
55 create a UNIX mailbox file with the patch emails. This mailbox file
56 can be previewed with any mail user agent which supports UNIX mbox
56 can be previewed with any mail user agent which supports UNIX mbox
57 files, e.g. with mutt::
57 files, e.g. with mutt::
58
58
59 % mutt -R -f mbox
59 % mutt -R -f mbox
60
60
61 When you are previewing the patchbomb messages, you can use ``formail``
61 When you are previewing the patchbomb messages, you can use ``formail``
62 (a utility that is commonly installed as part of the procmail
62 (a utility that is commonly installed as part of the procmail
63 package), to send each message out::
63 package), to send each message out::
64
64
65 % formail -s sendmail -bm -t < mbox
65 % formail -s sendmail -bm -t < mbox
66
66
67 That should be all. Now your patchbomb is on its way out.
67 That should be all. Now your patchbomb is on its way out.
68
68
69 You can also either configure the method option in the email section
69 You can also either configure the method option in the email section
70 to be a sendmail compatible mailer or fill out the [smtp] section so
70 to be a sendmail compatible mailer or fill out the [smtp] section so
71 that the patchbomb extension can automatically send patchbombs
71 that the patchbomb extension can automatically send patchbombs
72 directly from the commandline. See the [email] and [smtp] sections in
72 directly from the commandline. See the [email] and [smtp] sections in
73 hgrc(5) for details.
73 hgrc(5) for details.
74 '''
74 '''
75
75
76 import os, errno, socket, tempfile, cStringIO, time
76 import os, errno, socket, tempfile, cStringIO, time
77 import email.MIMEMultipart, email.MIMEBase
77 import email.MIMEMultipart, email.MIMEBase
78 import email.Utils, email.Encoders, email.Generator
78 import email.Utils, email.Encoders, email.Generator
79 from mercurial import cmdutil, commands, hg, mail, patch, util, discovery
79 from mercurial import cmdutil, commands, hg, mail, patch, util, discovery
80 from mercurial.i18n import _
80 from mercurial.i18n import _
81 from mercurial.node import bin
81 from mercurial.node import bin
82
82
83 def prompt(ui, prompt, default=None, rest=':'):
83 def prompt(ui, prompt, default=None, rest=':'):
84 if not ui.interactive() and default is None:
84 if not ui.interactive() and default is None:
85 raise util.Abort(_("%s Please enter a valid value" % (prompt + rest)))
85 raise util.Abort(_("%s Please enter a valid value" % (prompt + rest)))
86 if default:
86 if default:
87 prompt += ' [%s]' % default
87 prompt += ' [%s]' % default
88 prompt += rest
88 prompt += rest
89 while True:
89 while True:
90 r = ui.prompt(prompt, default=default)
90 r = ui.prompt(prompt, default=default)
91 if r:
91 if r:
92 return r
92 return r
93 if default is not None:
93 if default is not None:
94 return default
94 return default
95 ui.warn(_('Please enter a valid value.\n'))
95 ui.warn(_('Please enter a valid value.\n'))
96
96
97 def introneeded(opts, number):
97 def introneeded(opts, number):
98 '''is an introductory message required?'''
98 '''is an introductory message required?'''
99 return number > 1 or opts.get('intro') or opts.get('desc')
99 return number > 1 or opts.get('intro') or opts.get('desc')
100
100
101 def makepatch(ui, repo, patchlines, opts, _charsets, idx, total,
101 def makepatch(ui, repo, patchlines, opts, _charsets, idx, total,
102 patchname=None):
102 patchname=None):
103
103
104 desc = []
104 desc = []
105 node = None
105 node = None
106 body = ''
106 body = ''
107
107
108 for line in patchlines:
108 for line in patchlines:
109 if line.startswith('#'):
109 if line.startswith('#'):
110 if line.startswith('# Node ID'):
110 if line.startswith('# Node ID'):
111 node = line.split()[-1]
111 node = line.split()[-1]
112 continue
112 continue
113 if line.startswith('diff -r') or line.startswith('diff --git'):
113 if line.startswith('diff -r') or line.startswith('diff --git'):
114 break
114 break
115 desc.append(line)
115 desc.append(line)
116
116
117 if not patchname and not node:
117 if not patchname and not node:
118 raise ValueError
118 raise ValueError
119
119
120 if opts.get('attach'):
120 if opts.get('attach'):
121 body = ('\n'.join(desc[1:]).strip() or
121 body = ('\n'.join(desc[1:]).strip() or
122 'Patch subject is complete summary.')
122 'Patch subject is complete summary.')
123 body += '\n\n\n'
123 body += '\n\n\n'
124
124
125 if opts.get('plain'):
125 if opts.get('plain'):
126 while patchlines and patchlines[0].startswith('# '):
126 while patchlines and patchlines[0].startswith('# '):
127 patchlines.pop(0)
127 patchlines.pop(0)
128 if patchlines:
128 if patchlines:
129 patchlines.pop(0)
129 patchlines.pop(0)
130 while patchlines and not patchlines[0].strip():
130 while patchlines and not patchlines[0].strip():
131 patchlines.pop(0)
131 patchlines.pop(0)
132
132
133 ds = patch.diffstat(patchlines)
133 ds = patch.diffstat(patchlines)
134 if opts.get('diffstat'):
134 if opts.get('diffstat'):
135 body += ds + '\n\n'
135 body += ds + '\n\n'
136
136
137 if opts.get('attach') or opts.get('inline'):
137 if opts.get('attach') or opts.get('inline'):
138 msg = email.MIMEMultipart.MIMEMultipart()
138 msg = email.MIMEMultipart.MIMEMultipart()
139 if body:
139 if body:
140 msg.attach(mail.mimeencode(ui, body, _charsets, opts.get('test')))
140 msg.attach(mail.mimeencode(ui, body, _charsets, opts.get('test')))
141 p = mail.mimetextpatch('\n'.join(patchlines), 'x-patch', opts.get('test'))
141 p = mail.mimetextpatch('\n'.join(patchlines), 'x-patch', opts.get('test'))
142 binnode = bin(node)
142 binnode = bin(node)
143 # if node is mq patch, it will have the patch file's name as a tag
143 # if node is mq patch, it will have the patch file's name as a tag
144 if not patchname:
144 if not patchname:
145 patchtags = [t for t in repo.nodetags(binnode)
145 patchtags = [t for t in repo.nodetags(binnode)
146 if t.endswith('.patch') or t.endswith('.diff')]
146 if t.endswith('.patch') or t.endswith('.diff')]
147 if patchtags:
147 if patchtags:
148 patchname = patchtags[0]
148 patchname = patchtags[0]
149 elif total > 1:
149 elif total > 1:
150 patchname = cmdutil.make_filename(repo, '%b-%n.patch',
150 patchname = cmdutil.make_filename(repo, '%b-%n.patch',
151 binnode, seqno=idx, total=total)
151 binnode, seqno=idx, total=total)
152 else:
152 else:
153 patchname = cmdutil.make_filename(repo, '%b.patch', binnode)
153 patchname = cmdutil.make_filename(repo, '%b.patch', binnode)
154 disposition = 'inline'
154 disposition = 'inline'
155 if opts.get('attach'):
155 if opts.get('attach'):
156 disposition = 'attachment'
156 disposition = 'attachment'
157 p['Content-Disposition'] = disposition + '; filename=' + patchname
157 p['Content-Disposition'] = disposition + '; filename=' + patchname
158 msg.attach(p)
158 msg.attach(p)
159 else:
159 else:
160 body += '\n'.join(patchlines)
160 body += '\n'.join(patchlines)
161 msg = mail.mimetextpatch(body, display=opts.get('test'))
161 msg = mail.mimetextpatch(body, display=opts.get('test'))
162
162
163 flag = ' '.join(opts.get('flag'))
163 flag = ' '.join(opts.get('flag'))
164 if flag:
164 if flag:
165 flag = ' ' + flag
165 flag = ' ' + flag
166
166
167 subj = desc[0].strip().rstrip('. ')
167 subj = desc[0].strip().rstrip('. ')
168 if not introneeded(opts, total):
168 if not introneeded(opts, total):
169 subj = '[PATCH%s] %s' % (flag, opts.get('subject') or subj)
169 subj = '[PATCH%s] %s' % (flag, opts.get('subject') or subj)
170 else:
170 else:
171 tlen = len(str(total))
171 tlen = len(str(total))
172 subj = '[PATCH %0*d of %d%s] %s' % (tlen, idx, total, flag, subj)
172 subj = '[PATCH %0*d of %d%s] %s' % (tlen, idx, total, flag, subj)
173 msg['Subject'] = mail.headencode(ui, subj, _charsets, opts.get('test'))
173 msg['Subject'] = mail.headencode(ui, subj, _charsets, opts.get('test'))
174 msg['X-Mercurial-Node'] = node
174 msg['X-Mercurial-Node'] = node
175 return msg, subj, ds
175 return msg, subj, ds
176
176
177 def patchbomb(ui, repo, *revs, **opts):
177 def patchbomb(ui, repo, *revs, **opts):
178 '''send changesets by email
178 '''send changesets by email
179
179
180 By default, diffs are sent in the format generated by
180 By default, diffs are sent in the format generated by
181 :hg:`export`, one per message. The series starts with a "[PATCH 0
181 :hg:`export`, one per message. The series starts with a "[PATCH 0
182 of N]" introduction, which describes the series as a whole.
182 of N]" introduction, which describes the series as a whole.
183
183
184 Each patch email has a Subject line of "[PATCH M of N] ...", using
184 Each patch email has a Subject line of "[PATCH M of N] ...", using
185 the first line of the changeset description as the subject text.
185 the first line of the changeset description as the subject text.
186 The message contains two or three parts. First, the changeset
186 The message contains two or three parts. First, the changeset
187 description. Next, (optionally) if the diffstat program is
187 description. Next, (optionally) if the diffstat program is
188 installed and -d/--diffstat is used, the result of running
188 installed and -d/--diffstat is used, the result of running
189 diffstat on the patch. Finally, the patch itself, as generated by
189 diffstat on the patch. Finally, the patch itself, as generated by
190 :hg:`export`.
190 :hg:`export`.
191
191
192 By default the patch is included as text in the email body for
192 By default the patch is included as text in the email body for
193 easy reviewing. Using the -a/--attach option will instead create
193 easy reviewing. Using the -a/--attach option will instead create
194 an attachment for the patch. With -i/--inline an inline attachment
194 an attachment for the patch. With -i/--inline an inline attachment
195 will be created.
195 will be created.
196
196
197 With -o/--outgoing, emails will be generated for patches not found
197 With -o/--outgoing, emails will be generated for patches not found
198 in the destination repository (or only those which are ancestors
198 in the destination repository (or only those which are ancestors
199 of the specified revisions if any are provided)
199 of the specified revisions if any are provided)
200
200
201 With -b/--bundle, changesets are selected as for --outgoing, but a
201 With -b/--bundle, changesets are selected as for --outgoing, but a
202 single email containing a binary Mercurial bundle as an attachment
202 single email containing a binary Mercurial bundle as an attachment
203 will be sent.
203 will be sent.
204
204
205 Examples::
205 Examples::
206
206
207 hg email -r 3000 # send patch 3000 only
207 hg email -r 3000 # send patch 3000 only
208 hg email -r 3000 -r 3001 # send patches 3000 and 3001
208 hg email -r 3000 -r 3001 # send patches 3000 and 3001
209 hg email -r 3000:3005 # send patches 3000 through 3005
209 hg email -r 3000:3005 # send patches 3000 through 3005
210 hg email 3000 # send patch 3000 (deprecated)
210 hg email 3000 # send patch 3000 (deprecated)
211
211
212 hg email -o # send all patches not in default
212 hg email -o # send all patches not in default
213 hg email -o DEST # send all patches not in DEST
213 hg email -o DEST # send all patches not in DEST
214 hg email -o -r 3000 # send all ancestors of 3000 not in default
214 hg email -o -r 3000 # send all ancestors of 3000 not in default
215 hg email -o -r 3000 DEST # send all ancestors of 3000 not in DEST
215 hg email -o -r 3000 DEST # send all ancestors of 3000 not in DEST
216
216
217 hg email -b # send bundle of all patches not in default
217 hg email -b # send bundle of all patches not in default
218 hg email -b DEST # send bundle of all patches not in DEST
218 hg email -b DEST # send bundle of all patches not in DEST
219 hg email -b -r 3000 # bundle of all ancestors of 3000 not in default
219 hg email -b -r 3000 # bundle of all ancestors of 3000 not in default
220 hg email -b -r 3000 DEST # bundle of all ancestors of 3000 not in DEST
220 hg email -b -r 3000 DEST # bundle of all ancestors of 3000 not in DEST
221
221
222 Before using this command, you will need to enable email in your
222 Before using this command, you will need to enable email in your
223 hgrc. See the [email] section in hgrc(5) for details.
223 hgrc. See the [email] section in hgrc(5) for details.
224 '''
224 '''
225
225
226 _charsets = mail._charsets(ui)
226 _charsets = mail._charsets(ui)
227
227
228 bundle = opts.get('bundle')
228 bundle = opts.get('bundle')
229 date = opts.get('date')
229 date = opts.get('date')
230 mbox = opts.get('mbox')
230 mbox = opts.get('mbox')
231 outgoing = opts.get('outgoing')
231 outgoing = opts.get('outgoing')
232 rev = opts.get('rev')
232 rev = opts.get('rev')
233 # internal option used by pbranches
233 # internal option used by pbranches
234 patches = opts.get('patches')
234 patches = opts.get('patches')
235
235
236 def getoutgoing(dest, revs):
236 def getoutgoing(dest, revs):
237 '''Return the revisions present locally but not in dest'''
237 '''Return the revisions present locally but not in dest'''
238 dest = ui.expandpath(dest or 'default-push', dest or 'default')
238 dest = ui.expandpath(dest or 'default-push', dest or 'default')
239 dest, branches = hg.parseurl(dest)
239 dest, branches = hg.parseurl(dest)
240 revs, checkout = hg.addbranchrevs(repo, repo, branches, revs)
240 revs, checkout = hg.addbranchrevs(repo, repo, branches, revs)
241 if revs:
241 if revs:
242 revs = [repo.lookup(rev) for rev in revs]
242 revs = [repo.lookup(rev) for rev in revs]
243 other = hg.repository(hg.remoteui(repo, opts), dest)
243 other = hg.repository(hg.remoteui(repo, opts), dest)
244 ui.status(_('comparing with %s\n') % dest)
244 ui.status(_('comparing with %s\n') % dest)
245 o = discovery.findoutgoing(repo, other)
245 o = discovery.findoutgoing(repo, other)
246 if not o:
246 if not o:
247 ui.status(_("no changes found\n"))
247 ui.status(_("no changes found\n"))
248 return []
248 return []
249 o = repo.changelog.nodesbetween(o, revs)[0]
249 o = repo.changelog.nodesbetween(o, revs)[0]
250 return [str(repo.changelog.rev(r)) for r in o]
250 return [str(repo.changelog.rev(r)) for r in o]
251
251
252 def getpatches(revs):
252 def getpatches(revs):
253 for r in cmdutil.revrange(repo, revs):
253 for r in cmdutil.revrange(repo, revs):
254 output = cStringIO.StringIO()
254 output = cStringIO.StringIO()
255 cmdutil.export(repo, [r], fp=output,
255 cmdutil.export(repo, [r], fp=output,
256 opts=patch.diffopts(ui, opts))
256 opts=patch.diffopts(ui, opts))
257 yield output.getvalue().split('\n')
257 yield output.getvalue().split('\n')
258
258
259 def getbundle(dest):
259 def getbundle(dest):
260 tmpdir = tempfile.mkdtemp(prefix='hg-email-bundle-')
260 tmpdir = tempfile.mkdtemp(prefix='hg-email-bundle-')
261 tmpfn = os.path.join(tmpdir, 'bundle')
261 tmpfn = os.path.join(tmpdir, 'bundle')
262 try:
262 try:
263 commands.bundle(ui, repo, tmpfn, dest, **opts)
263 commands.bundle(ui, repo, tmpfn, dest, **opts)
264 return open(tmpfn, 'rb').read()
264 return open(tmpfn, 'rb').read()
265 finally:
265 finally:
266 try:
266 try:
267 os.unlink(tmpfn)
267 os.unlink(tmpfn)
268 except:
268 except:
269 pass
269 pass
270 os.rmdir(tmpdir)
270 os.rmdir(tmpdir)
271
271
272 if not (opts.get('test') or mbox):
272 if not (opts.get('test') or mbox):
273 # really sending
273 # really sending
274 mail.validateconfig(ui)
274 mail.validateconfig(ui)
275
275
276 if not (revs or rev or outgoing or bundle or patches):
276 if not (revs or rev or outgoing or bundle or patches):
277 raise util.Abort(_('specify at least one changeset with -r or -o'))
277 raise util.Abort(_('specify at least one changeset with -r or -o'))
278
278
279 if outgoing and bundle:
279 if outgoing and bundle:
280 raise util.Abort(_("--outgoing mode always on with --bundle;"
280 raise util.Abort(_("--outgoing mode always on with --bundle;"
281 " do not re-specify --outgoing"))
281 " do not re-specify --outgoing"))
282
282
283 if outgoing or bundle:
283 if outgoing or bundle:
284 if len(revs) > 1:
284 if len(revs) > 1:
285 raise util.Abort(_("too many destinations"))
285 raise util.Abort(_("too many destinations"))
286 dest = revs and revs[0] or None
286 dest = revs and revs[0] or None
287 revs = []
287 revs = []
288
288
289 if rev:
289 if rev:
290 if revs:
290 if revs:
291 raise util.Abort(_('use only one form to specify the revision'))
291 raise util.Abort(_('use only one form to specify the revision'))
292 revs = rev
292 revs = rev
293
293
294 if outgoing:
294 if outgoing:
295 revs = getoutgoing(dest, rev)
295 revs = getoutgoing(dest, rev)
296 if bundle:
296 if bundle:
297 opts['revs'] = revs
297 opts['revs'] = revs
298
298
299 # start
299 # start
300 if date:
300 if date:
301 start_time = util.parsedate(date)
301 start_time = util.parsedate(date)
302 else:
302 else:
303 start_time = util.makedate()
303 start_time = util.makedate()
304
304
305 def genmsgid(id):
305 def genmsgid(id):
306 return '<%s.%s@%s>' % (id[:20], int(start_time[0]), socket.getfqdn())
306 return '<%s.%s@%s>' % (id[:20], int(start_time[0]), socket.getfqdn())
307
307
308 def getdescription(body, sender):
308 def getdescription(body, sender):
309 if opts.get('desc'):
309 if opts.get('desc'):
310 body = open(opts.get('desc')).read()
310 body = open(opts.get('desc')).read()
311 else:
311 else:
312 ui.write(_('\nWrite the introductory message for the '
312 ui.write(_('\nWrite the introductory message for the '
313 'patch series.\n\n'))
313 'patch series.\n\n'))
314 body = ui.edit(body, sender)
314 body = ui.edit(body, sender)
315 return body
315 return body
316
316
317 def getpatchmsgs(patches, patchnames=None):
317 def getpatchmsgs(patches, patchnames=None):
318 jumbo = []
318 jumbo = []
319 msgs = []
319 msgs = []
320
320
321 ui.write(_('This patch series consists of %d patches.\n\n')
321 ui.write(_('This patch series consists of %d patches.\n\n')
322 % len(patches))
322 % len(patches))
323
323
324 name = None
324 name = None
325 for i, p in enumerate(patches):
325 for i, p in enumerate(patches):
326 jumbo.extend(p)
326 jumbo.extend(p)
327 if patchnames:
327 if patchnames:
328 name = patchnames[i]
328 name = patchnames[i]
329 msg = makepatch(ui, repo, p, opts, _charsets, i + 1,
329 msg = makepatch(ui, repo, p, opts, _charsets, i + 1,
330 len(patches), name)
330 len(patches), name)
331 msgs.append(msg)
331 msgs.append(msg)
332
332
333 if introneeded(opts, len(patches)):
333 if introneeded(opts, len(patches)):
334 tlen = len(str(len(patches)))
334 tlen = len(str(len(patches)))
335
335
336 flag = ' '.join(opts.get('flag'))
336 flag = ' '.join(opts.get('flag'))
337 if flag:
337 if flag:
338 subj = '[PATCH %0*d of %d %s]' % (tlen, 0, len(patches), flag)
338 subj = '[PATCH %0*d of %d %s]' % (tlen, 0, len(patches), flag)
339 else:
339 else:
340 subj = '[PATCH %0*d of %d]' % (tlen, 0, len(patches))
340 subj = '[PATCH %0*d of %d]' % (tlen, 0, len(patches))
341 subj += ' ' + (opts.get('subject') or
341 subj += ' ' + (opts.get('subject') or
342 prompt(ui, 'Subject: ', rest=subj))
342 prompt(ui, 'Subject: ', rest=subj))
343
343
344 body = ''
344 body = ''
345 ds = patch.diffstat(jumbo)
345 ds = patch.diffstat(jumbo)
346 if ds and opts.get('diffstat'):
346 if ds and opts.get('diffstat'):
347 body = '\n' + ds
347 body = '\n' + ds
348
348
349 body = getdescription(body, sender)
349 body = getdescription(body, sender)
350 msg = mail.mimeencode(ui, body, _charsets, opts.get('test'))
350 msg = mail.mimeencode(ui, body, _charsets, opts.get('test'))
351 msg['Subject'] = mail.headencode(ui, subj, _charsets,
351 msg['Subject'] = mail.headencode(ui, subj, _charsets,
352 opts.get('test'))
352 opts.get('test'))
353
353
354 msgs.insert(0, (msg, subj, ds))
354 msgs.insert(0, (msg, subj, ds))
355 return msgs
355 return msgs
356
356
357 def getbundlemsgs(bundle):
357 def getbundlemsgs(bundle):
358 subj = (opts.get('subject')
358 subj = (opts.get('subject')
359 or prompt(ui, 'Subject:', 'A bundle for your repository'))
359 or prompt(ui, 'Subject:', 'A bundle for your repository'))
360
360
361 body = getdescription('', sender)
361 body = getdescription('', sender)
362 msg = email.MIMEMultipart.MIMEMultipart()
362 msg = email.MIMEMultipart.MIMEMultipart()
363 if body:
363 if body:
364 msg.attach(mail.mimeencode(ui, body, _charsets, opts.get('test')))
364 msg.attach(mail.mimeencode(ui, body, _charsets, opts.get('test')))
365 datapart = email.MIMEBase.MIMEBase('application', 'x-mercurial-bundle')
365 datapart = email.MIMEBase.MIMEBase('application', 'x-mercurial-bundle')
366 datapart.set_payload(bundle)
366 datapart.set_payload(bundle)
367 bundlename = '%s.hg' % opts.get('bundlename', 'bundle')
367 bundlename = '%s.hg' % opts.get('bundlename', 'bundle')
368 datapart.add_header('Content-Disposition', 'attachment',
368 datapart.add_header('Content-Disposition', 'attachment',
369 filename=bundlename)
369 filename=bundlename)
370 email.Encoders.encode_base64(datapart)
370 email.Encoders.encode_base64(datapart)
371 msg.attach(datapart)
371 msg.attach(datapart)
372 msg['Subject'] = mail.headencode(ui, subj, _charsets, opts.get('test'))
372 msg['Subject'] = mail.headencode(ui, subj, _charsets, opts.get('test'))
373 return [(msg, subj, None)]
373 return [(msg, subj, None)]
374
374
375 sender = (opts.get('from') or ui.config('email', 'from') or
375 sender = (opts.get('from') or ui.config('email', 'from') or
376 ui.config('patchbomb', 'from') or
376 ui.config('patchbomb', 'from') or
377 prompt(ui, 'From', ui.username()))
377 prompt(ui, 'From', ui.username()))
378
378
379 if patches:
379 if patches:
380 msgs = getpatchmsgs(patches, opts.get('patchnames'))
380 msgs = getpatchmsgs(patches, opts.get('patchnames'))
381 elif bundle:
381 elif bundle:
382 msgs = getbundlemsgs(getbundle(dest))
382 msgs = getbundlemsgs(getbundle(dest))
383 else:
383 else:
384 msgs = getpatchmsgs(list(getpatches(revs)))
384 msgs = getpatchmsgs(list(getpatches(revs)))
385
385
386 showaddrs = []
386 showaddrs = []
387
387
388 def getaddrs(opt, prpt=None, default=None):
388 def getaddrs(opt, prpt=None, default=None):
389 addrs = opts.get(opt.replace('-', '_'))
389 addrs = opts.get(opt.replace('-', '_'))
390 if opt != 'reply-to':
390 if opt != 'reply-to':
391 showaddr = '%s:' % opt.capitalize()
391 showaddr = '%s:' % opt.capitalize()
392 else:
392 else:
393 showaddr = 'Reply-To:'
393 showaddr = 'Reply-To:'
394
394
395 if addrs:
395 if addrs:
396 showaddrs.append('%s %s' % (showaddr, ', '.join(addrs)))
396 showaddrs.append('%s %s' % (showaddr, ', '.join(addrs)))
397 return mail.addrlistencode(ui, addrs, _charsets,
397 return mail.addrlistencode(ui, addrs, _charsets,
398 opts.get('test'))
398 opts.get('test'))
399
399
400 addrs = ui.config('email', opt) or ui.config('patchbomb', opt) or ''
400 addrs = ui.config('email', opt) or ui.config('patchbomb', opt) or ''
401 if not addrs and prpt:
401 if not addrs and prpt:
402 addrs = prompt(ui, prpt, default)
402 addrs = prompt(ui, prpt, default)
403
403
404 if addrs:
404 if addrs:
405 showaddr = '%s %s' % (showaddr, addrs)
405 showaddr = '%s %s' % (showaddr, addrs)
406 showaddrs.append(showaddr)
406 showaddrs.append(showaddr)
407
407
408 return mail.addrlistencode(ui, [addrs], _charsets, opts.get('test'))
408 return mail.addrlistencode(ui, [addrs], _charsets, opts.get('test'))
409
409
410 to = getaddrs('to', 'To')
410 to = getaddrs('to', 'To')
411 cc = getaddrs('cc', 'Cc', '')
411 cc = getaddrs('cc', 'Cc', '')
412 bcc = getaddrs('bcc')
412 bcc = getaddrs('bcc')
413 replyto = getaddrs('reply-to')
413 replyto = getaddrs('reply-to')
414
414
415 if opts.get('diffstat'):
415 if opts.get('diffstat') or opts.get('confirm'):
416 ui.write(_('\nFinal summary:\n\n'))
416 ui.write(_('\nFinal summary:\n\n'))
417 ui.write('From: %s\n' % sender)
417 ui.write('From: %s\n' % sender)
418 for addr in showaddrs:
418 for addr in showaddrs:
419 ui.write('%s\n' % addr)
419 ui.write('%s\n' % addr)
420 for m, subj, ds in msgs:
420 for m, subj, ds in msgs:
421 ui.write('Subject: %s\n' % subj)
421 ui.write('Subject: %s\n' % subj)
422 if ds:
422 if ds:
423 ui.write(ds)
423 ui.write(ds)
424 ui.write('\n')
424 ui.write('\n')
425 if ui.promptchoice(_('are you sure you want to send (yn)?'),
425 if ui.promptchoice(_('are you sure you want to send (yn)?'),
426 (_('&Yes'), _('&No'))):
426 (_('&Yes'), _('&No'))):
427 raise util.Abort(_('patchbomb canceled'))
427 raise util.Abort(_('patchbomb canceled'))
428
428
429 ui.write('\n')
429 ui.write('\n')
430
430
431 parent = opts.get('in_reply_to') or None
431 parent = opts.get('in_reply_to') or None
432 # angle brackets may be omitted, they're not semantically part of the msg-id
432 # angle brackets may be omitted, they're not semantically part of the msg-id
433 if parent is not None:
433 if parent is not None:
434 if not parent.startswith('<'):
434 if not parent.startswith('<'):
435 parent = '<' + parent
435 parent = '<' + parent
436 if not parent.endswith('>'):
436 if not parent.endswith('>'):
437 parent += '>'
437 parent += '>'
438
438
439 first = True
439 first = True
440
440
441 sender_addr = email.Utils.parseaddr(sender)[1]
441 sender_addr = email.Utils.parseaddr(sender)[1]
442 sender = mail.addressencode(ui, sender, _charsets, opts.get('test'))
442 sender = mail.addressencode(ui, sender, _charsets, opts.get('test'))
443 sendmail = None
443 sendmail = None
444 for m, subj, ds in msgs:
444 for m, subj, ds in msgs:
445 try:
445 try:
446 m['Message-Id'] = genmsgid(m['X-Mercurial-Node'])
446 m['Message-Id'] = genmsgid(m['X-Mercurial-Node'])
447 except TypeError:
447 except TypeError:
448 m['Message-Id'] = genmsgid('patchbomb')
448 m['Message-Id'] = genmsgid('patchbomb')
449 if parent:
449 if parent:
450 m['In-Reply-To'] = parent
450 m['In-Reply-To'] = parent
451 m['References'] = parent
451 m['References'] = parent
452 if first:
452 if first:
453 parent = m['Message-Id']
453 parent = m['Message-Id']
454 first = False
454 first = False
455
455
456 m['User-Agent'] = 'Mercurial-patchbomb/%s' % util.version()
456 m['User-Agent'] = 'Mercurial-patchbomb/%s' % util.version()
457 m['Date'] = email.Utils.formatdate(start_time[0], localtime=True)
457 m['Date'] = email.Utils.formatdate(start_time[0], localtime=True)
458
458
459 start_time = (start_time[0] + 1, start_time[1])
459 start_time = (start_time[0] + 1, start_time[1])
460 m['From'] = sender
460 m['From'] = sender
461 m['To'] = ', '.join(to)
461 m['To'] = ', '.join(to)
462 if cc:
462 if cc:
463 m['Cc'] = ', '.join(cc)
463 m['Cc'] = ', '.join(cc)
464 if bcc:
464 if bcc:
465 m['Bcc'] = ', '.join(bcc)
465 m['Bcc'] = ', '.join(bcc)
466 if replyto:
466 if replyto:
467 m['Reply-To'] = ', '.join(replyto)
467 m['Reply-To'] = ', '.join(replyto)
468 if opts.get('test'):
468 if opts.get('test'):
469 ui.status(_('Displaying '), subj, ' ...\n')
469 ui.status(_('Displaying '), subj, ' ...\n')
470 ui.flush()
470 ui.flush()
471 if 'PAGER' in os.environ and not ui.plain():
471 if 'PAGER' in os.environ and not ui.plain():
472 fp = util.popen(os.environ['PAGER'], 'w')
472 fp = util.popen(os.environ['PAGER'], 'w')
473 else:
473 else:
474 fp = ui
474 fp = ui
475 generator = email.Generator.Generator(fp, mangle_from_=False)
475 generator = email.Generator.Generator(fp, mangle_from_=False)
476 try:
476 try:
477 generator.flatten(m, 0)
477 generator.flatten(m, 0)
478 fp.write('\n')
478 fp.write('\n')
479 except IOError, inst:
479 except IOError, inst:
480 if inst.errno != errno.EPIPE:
480 if inst.errno != errno.EPIPE:
481 raise
481 raise
482 if fp is not ui:
482 if fp is not ui:
483 fp.close()
483 fp.close()
484 elif mbox:
484 elif mbox:
485 ui.status(_('Writing '), subj, ' ...\n')
485 ui.status(_('Writing '), subj, ' ...\n')
486 fp = open(mbox, 'In-Reply-To' in m and 'ab+' or 'wb+')
486 fp = open(mbox, 'In-Reply-To' in m and 'ab+' or 'wb+')
487 generator = email.Generator.Generator(fp, mangle_from_=True)
487 generator = email.Generator.Generator(fp, mangle_from_=True)
488 # Should be time.asctime(), but Windows prints 2-characters day
488 # Should be time.asctime(), but Windows prints 2-characters day
489 # of month instead of one. Make them print the same thing.
489 # of month instead of one. Make them print the same thing.
490 date = time.strftime('%a %b %d %H:%M:%S %Y',
490 date = time.strftime('%a %b %d %H:%M:%S %Y',
491 time.localtime(start_time[0]))
491 time.localtime(start_time[0]))
492 fp.write('From %s %s\n' % (sender_addr, date))
492 fp.write('From %s %s\n' % (sender_addr, date))
493 generator.flatten(m, 0)
493 generator.flatten(m, 0)
494 fp.write('\n\n')
494 fp.write('\n\n')
495 fp.close()
495 fp.close()
496 else:
496 else:
497 if not sendmail:
497 if not sendmail:
498 sendmail = mail.connect(ui)
498 sendmail = mail.connect(ui)
499 ui.status(_('Sending '), subj, ' ...\n')
499 ui.status(_('Sending '), subj, ' ...\n')
500 # Exim does not remove the Bcc field
500 # Exim does not remove the Bcc field
501 del m['Bcc']
501 del m['Bcc']
502 fp = cStringIO.StringIO()
502 fp = cStringIO.StringIO()
503 generator = email.Generator.Generator(fp, mangle_from_=False)
503 generator = email.Generator.Generator(fp, mangle_from_=False)
504 generator.flatten(m, 0)
504 generator.flatten(m, 0)
505 sendmail(sender, to + bcc + cc, fp.getvalue())
505 sendmail(sender, to + bcc + cc, fp.getvalue())
506
506
507 emailopts = [
507 emailopts = [
508 ('a', 'attach', None, _('send patches as attachments')),
508 ('a', 'attach', None, _('send patches as attachments')),
509 ('i', 'inline', None, _('send patches as inline attachments')),
509 ('i', 'inline', None, _('send patches as inline attachments')),
510 ('', 'bcc', [], _('email addresses of blind carbon copy recipients')),
510 ('', 'bcc', [], _('email addresses of blind carbon copy recipients')),
511 ('c', 'cc', [], _('email addresses of copy recipients')),
511 ('c', 'cc', [], _('email addresses of copy recipients')),
512 ('', 'confirm', None, _('ask for confirmation before sending')),
512 ('d', 'diffstat', None, _('add diffstat output to messages')),
513 ('d', 'diffstat', None, _('add diffstat output to messages')),
513 ('', 'date', '', _('use the given date as the sending date')),
514 ('', 'date', '', _('use the given date as the sending date')),
514 ('', 'desc', '', _('use the given file as the series description')),
515 ('', 'desc', '', _('use the given file as the series description')),
515 ('f', 'from', '', _('email address of sender')),
516 ('f', 'from', '', _('email address of sender')),
516 ('n', 'test', None, _('print messages that would be sent')),
517 ('n', 'test', None, _('print messages that would be sent')),
517 ('m', 'mbox', '',
518 ('m', 'mbox', '',
518 _('write messages to mbox file instead of sending them')),
519 _('write messages to mbox file instead of sending them')),
519 ('', 'reply-to', [], _('email addresses replies should be sent to')),
520 ('', 'reply-to', [], _('email addresses replies should be sent to')),
520 ('s', 'subject', '',
521 ('s', 'subject', '',
521 _('subject of first message (intro or single patch)')),
522 _('subject of first message (intro or single patch)')),
522 ('', 'in-reply-to', '',
523 ('', 'in-reply-to', '',
523 _('message identifier to reply to')),
524 _('message identifier to reply to')),
524 ('', 'flag', [], _('flags to add in subject prefixes')),
525 ('', 'flag', [], _('flags to add in subject prefixes')),
525 ('t', 'to', [], _('email addresses of recipients')),
526 ('t', 'to', [], _('email addresses of recipients')),
526 ]
527 ]
527
528
528
529
529 cmdtable = {
530 cmdtable = {
530 "email":
531 "email":
531 (patchbomb,
532 (patchbomb,
532 [('g', 'git', None, _('use git extended diff format')),
533 [('g', 'git', None, _('use git extended diff format')),
533 ('', 'plain', None, _('omit hg patch header')),
534 ('', 'plain', None, _('omit hg patch header')),
534 ('o', 'outgoing', None,
535 ('o', 'outgoing', None,
535 _('send changes not found in the target repository')),
536 _('send changes not found in the target repository')),
536 ('b', 'bundle', None,
537 ('b', 'bundle', None,
537 _('send changes not in target as a binary bundle')),
538 _('send changes not in target as a binary bundle')),
538 ('', 'bundlename', 'bundle',
539 ('', 'bundlename', 'bundle',
539 _('name of the bundle attachment file'), _('NAME')),
540 _('name of the bundle attachment file'), _('NAME')),
540 ('r', 'rev', [],
541 ('r', 'rev', [],
541 _('a revision to send'), _('REV')),
542 _('a revision to send'), _('REV')),
542 ('', 'force', None,
543 ('', 'force', None,
543 _('run even when remote repository is unrelated '
544 _('run even when remote repository is unrelated '
544 '(with -b/--bundle)')),
545 '(with -b/--bundle)')),
545 ('', 'base', [],
546 ('', 'base', [],
546 _('a base changeset to specify instead of a destination '
547 _('a base changeset to specify instead of a destination '
547 '(with -b/--bundle)'),
548 '(with -b/--bundle)'),
548 _('REV')),
549 _('REV')),
549 ('', 'intro', None,
550 ('', 'intro', None,
550 _('send an introduction email for a single patch')),
551 _('send an introduction email for a single patch')),
551 ] + emailopts + commands.remoteopts,
552 ] + emailopts + commands.remoteopts,
552 _('hg email [OPTION]... [DEST]...'))
553 _('hg email [OPTION]... [DEST]...'))
553 }
554 }
@@ -1,2132 +1,2149 b''
1 $ fixheaders()
1 $ fixheaders()
2 > {
2 > {
3 > sed -e 's/\(Message-Id:.*@\).*/\1/' \
3 > sed -e 's/\(Message-Id:.*@\).*/\1/' \
4 > -e 's/\(In-Reply-To:.*@\).*/\1/' \
4 > -e 's/\(In-Reply-To:.*@\).*/\1/' \
5 > -e 's/\(References:.*@\).*/\1/' \
5 > -e 's/\(References:.*@\).*/\1/' \
6 > -e 's/\(User-Agent:.*\)\/.*/\1/' \
6 > -e 's/\(User-Agent:.*\)\/.*/\1/' \
7 > -e 's/===.*/===/'
7 > -e 's/===.*/===/'
8 > }
8 > }
9 $ echo "[extensions]" >> $HGRCPATH
9 $ echo "[extensions]" >> $HGRCPATH
10 $ echo "patchbomb=" >> $HGRCPATH
10 $ echo "patchbomb=" >> $HGRCPATH
11
11
12 $ hg init t
12 $ hg init t
13 $ cd t
13 $ cd t
14 $ echo a > a
14 $ echo a > a
15 $ hg commit -Ama -d '1 0'
15 $ hg commit -Ama -d '1 0'
16 adding a
16 adding a
17
17
18 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -r tip
18 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -r tip
19 This patch series consists of 1 patches.
19 This patch series consists of 1 patches.
20
20
21
21
22 Displaying [PATCH] a ...
22 Displaying [PATCH] a ...
23 Content-Type: text/plain; charset="us-ascii"
23 Content-Type: text/plain; charset="us-ascii"
24 MIME-Version: 1.0
24 MIME-Version: 1.0
25 Content-Transfer-Encoding: 7bit
25 Content-Transfer-Encoding: 7bit
26 Subject: [PATCH] a
26 Subject: [PATCH] a
27 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
27 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
28 Message-Id: <8580ff50825a50c8f716.60@.*
28 Message-Id: <8580ff50825a50c8f716.60@.*
29 User-Agent: Mercurial-patchbomb/.*
29 User-Agent: Mercurial-patchbomb/.*
30 Date: Thu, 01 Jan 1970 00:01:00 +0000
30 Date: Thu, 01 Jan 1970 00:01:00 +0000
31 From: quux
31 From: quux
32 To: foo
32 To: foo
33 Cc: bar
33 Cc: bar
34
34
35 # HG changeset patch
35 # HG changeset patch
36 # User test
36 # User test
37 # Date 1 0
37 # Date 1 0
38 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
38 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
39 # Parent 0000000000000000000000000000000000000000
39 # Parent 0000000000000000000000000000000000000000
40 a
40 a
41
41
42 diff -r 000000000000 -r 8580ff50825a a
42 diff -r 000000000000 -r 8580ff50825a a
43 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
43 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
44 +++ b/a Thu Jan 01 00:00:01 1970 +0000
44 +++ b/a Thu Jan 01 00:00:01 1970 +0000
45 @@ -0,0 +1,1 @@
45 @@ -0,0 +1,1 @@
46 +a
46 +a
47
47
48
48
49 $ hg --config ui.interactive=1 email --confirm -n -f quux -t foo -c bar -r tip<<EOF
50 > n
51 > EOF
52 This patch series consists of 1 patches.
53
54
55 Final summary:
56
57 From: quux
58 To: foo
59 Cc: bar
60 Subject: [PATCH] a
61 a | 1 +
62 1 files changed, 1 insertions(+), 0 deletions(-)
63
64 are you sure you want to send (yn)? abort: patchbomb canceled
65
49 $ echo b > b
66 $ echo b > b
50 $ hg commit -Amb -d '2 0'
67 $ hg commit -Amb -d '2 0'
51 adding b
68 adding b
52
69
53 $ hg email --date '1970-1-1 0:2' -n -f quux -t foo -c bar -s test -r 0:tip
70 $ hg email --date '1970-1-1 0:2' -n -f quux -t foo -c bar -s test -r 0:tip
54 This patch series consists of 2 patches.
71 This patch series consists of 2 patches.
55
72
56
73
57 Write the introductory message for the patch series.
74 Write the introductory message for the patch series.
58
75
59
76
60 Displaying [PATCH 0 of 2] test ...
77 Displaying [PATCH 0 of 2] test ...
61 Content-Type: text/plain; charset="us-ascii"
78 Content-Type: text/plain; charset="us-ascii"
62 MIME-Version: 1.0
79 MIME-Version: 1.0
63 Content-Transfer-Encoding: 7bit
80 Content-Transfer-Encoding: 7bit
64 Subject: [PATCH 0 of 2] test
81 Subject: [PATCH 0 of 2] test
65 Message-Id: <patchbomb.120@[^>]*>
82 Message-Id: <patchbomb.120@[^>]*>
66 User-Agent: Mercurial-patchbomb/.*
83 User-Agent: Mercurial-patchbomb/.*
67 Date: Thu, 01 Jan 1970 00:02:00 +0000
84 Date: Thu, 01 Jan 1970 00:02:00 +0000
68 From: quux
85 From: quux
69 To: foo
86 To: foo
70 Cc: bar
87 Cc: bar
71
88
72
89
73 Displaying [PATCH 1 of 2] a ...
90 Displaying [PATCH 1 of 2] a ...
74 Content-Type: text/plain; charset="us-ascii"
91 Content-Type: text/plain; charset="us-ascii"
75 MIME-Version: 1.0
92 MIME-Version: 1.0
76 Content-Transfer-Encoding: 7bit
93 Content-Transfer-Encoding: 7bit
77 Subject: [PATCH 1 of 2] a
94 Subject: [PATCH 1 of 2] a
78 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
95 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
79 Message-Id: <8580ff50825a50c8f716.121@[^>]*>
96 Message-Id: <8580ff50825a50c8f716.121@[^>]*>
80 In-Reply-To: <patchbomb.120@[^>]*>
97 In-Reply-To: <patchbomb.120@[^>]*>
81 References: <patchbomb.120@[^>]*>
98 References: <patchbomb.120@[^>]*>
82 User-Agent: Mercurial-patchbomb/.*
99 User-Agent: Mercurial-patchbomb/.*
83 Date: Thu, 01 Jan 1970 00:02:01 +0000
100 Date: Thu, 01 Jan 1970 00:02:01 +0000
84 From: quux
101 From: quux
85 To: foo
102 To: foo
86 Cc: bar
103 Cc: bar
87
104
88 # HG changeset patch
105 # HG changeset patch
89 # User test
106 # User test
90 # Date 1 0
107 # Date 1 0
91 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
108 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
92 # Parent 0000000000000000000000000000000000000000
109 # Parent 0000000000000000000000000000000000000000
93 a
110 a
94
111
95 diff -r 000000000000 -r 8580ff50825a a
112 diff -r 000000000000 -r 8580ff50825a a
96 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
113 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
97 +++ b/a Thu Jan 01 00:00:01 1970 +0000
114 +++ b/a Thu Jan 01 00:00:01 1970 +0000
98 @@ -0,0 +1,1 @@
115 @@ -0,0 +1,1 @@
99 +a
116 +a
100
117
101 Displaying [PATCH 2 of 2] b ...
118 Displaying [PATCH 2 of 2] b ...
102 Content-Type: text/plain; charset="us-ascii"
119 Content-Type: text/plain; charset="us-ascii"
103 MIME-Version: 1.0
120 MIME-Version: 1.0
104 Content-Transfer-Encoding: 7bit
121 Content-Transfer-Encoding: 7bit
105 Subject: [PATCH 2 of 2] b
122 Subject: [PATCH 2 of 2] b
106 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
123 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
107 Message-Id: <97d72e5f12c7e84f8506.122@[^>]*>
124 Message-Id: <97d72e5f12c7e84f8506.122@[^>]*>
108 In-Reply-To: <patchbomb.120@[^>]*>
125 In-Reply-To: <patchbomb.120@[^>]*>
109 References: <patchbomb.120@[^>]*>
126 References: <patchbomb.120@[^>]*>
110 User-Agent: Mercurial-patchbomb/.*
127 User-Agent: Mercurial-patchbomb/.*
111 Date: Thu, 01 Jan 1970 00:02:02 +0000
128 Date: Thu, 01 Jan 1970 00:02:02 +0000
112 From: quux
129 From: quux
113 To: foo
130 To: foo
114 Cc: bar
131 Cc: bar
115
132
116 # HG changeset patch
133 # HG changeset patch
117 # User test
134 # User test
118 # Date 2 0
135 # Date 2 0
119 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
136 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
120 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
137 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
121 b
138 b
122
139
123 diff -r 8580ff50825a -r 97d72e5f12c7 b
140 diff -r 8580ff50825a -r 97d72e5f12c7 b
124 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
141 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
125 +++ b/b Thu Jan 01 00:00:02 1970 +0000
142 +++ b/b Thu Jan 01 00:00:02 1970 +0000
126 @@ -0,0 +1,1 @@
143 @@ -0,0 +1,1 @@
127 +b
144 +b
128
145
129
146
130 $ hg email -m test.mbox -f quux -t foo -c bar -s test 0:tip
147 $ hg email -m test.mbox -f quux -t foo -c bar -s test 0:tip
131 This patch series consists of 2 patches.
148 This patch series consists of 2 patches.
132
149
133
150
134 Write the introductory message for the patch series.
151 Write the introductory message for the patch series.
135
152
136
153
137 Writing [PATCH 0 of 2] test ...
154 Writing [PATCH 0 of 2] test ...
138 Writing [PATCH 1 of 2] a ...
155 Writing [PATCH 1 of 2] a ...
139 Writing [PATCH 2 of 2] b ...
156 Writing [PATCH 2 of 2] b ...
140
157
141 $ cd ..
158 $ cd ..
142
159
143 $ hg clone -q t t2
160 $ hg clone -q t t2
144 $ cd t2
161 $ cd t2
145 $ echo c > c
162 $ echo c > c
146 $ hg commit -Amc -d '3 0'
163 $ hg commit -Amc -d '3 0'
147 adding c
164 adding c
148
165
149 $ cat > description <<EOF
166 $ cat > description <<EOF
150 > a multiline
167 > a multiline
151 >
168 >
152 > description
169 > description
153 > EOF
170 > EOF
154
171
155
172
156 test bundle and description:
173 test bundle and description:
157 $ hg email --date '1970-1-1 0:3' -n -f quux -t foo \
174 $ hg email --date '1970-1-1 0:3' -n -f quux -t foo \
158 > -c bar -s test -r tip -b --desc description | fixheaders
175 > -c bar -s test -r tip -b --desc description | fixheaders
159 searching for changes
176 searching for changes
160 1 changesets found
177 1 changesets found
161
178
162 Displaying test ...
179 Displaying test ...
163 Content-Type: multipart/mixed; boundary="===
180 Content-Type: multipart/mixed; boundary="===
164 MIME-Version: 1.0
181 MIME-Version: 1.0
165 Subject: test
182 Subject: test
166 Message-Id: <patchbomb.180@
183 Message-Id: <patchbomb.180@
167 User-Agent: Mercurial-patchbomb
184 User-Agent: Mercurial-patchbomb
168 Date: Thu, 01 Jan 1970 00:03:00 +0000
185 Date: Thu, 01 Jan 1970 00:03:00 +0000
169 From: quux
186 From: quux
170 To: foo
187 To: foo
171 Cc: bar
188 Cc: bar
172
189
173 --===
190 --===
174 Content-Type: text/plain; charset="us-ascii"
191 Content-Type: text/plain; charset="us-ascii"
175 MIME-Version: 1.0
192 MIME-Version: 1.0
176 Content-Transfer-Encoding: 7bit
193 Content-Transfer-Encoding: 7bit
177
194
178 a multiline
195 a multiline
179
196
180 description
197 description
181
198
182 --===
199 --===
183 Content-Type: application/x-mercurial-bundle
200 Content-Type: application/x-mercurial-bundle
184 MIME-Version: 1.0
201 MIME-Version: 1.0
185 Content-Disposition: attachment; filename="bundle.hg"
202 Content-Disposition: attachment; filename="bundle.hg"
186 Content-Transfer-Encoding: base64
203 Content-Transfer-Encoding: base64
187
204
188 SEcxMEJaaDkxQVkmU1nvR7I3AAAN////lFYQWj1/4HwRkdC/AywIAk0E4pfoSIIIgQCgGEQOcLAA
205 SEcxMEJaaDkxQVkmU1nvR7I3AAAN////lFYQWj1/4HwRkdC/AywIAk0E4pfoSIIIgQCgGEQOcLAA
189 2tA1VPyp4mkeoG0EaaPU0GTT1GjRiNPIg9CZGBqZ6UbU9J+KFU09DNUaGgAAAAAANAGgAAAAA1U8
206 2tA1VPyp4mkeoG0EaaPU0GTT1GjRiNPIg9CZGBqZ6UbU9J+KFU09DNUaGgAAAAAANAGgAAAAA1U8
190 oGgAADQGgAANNANAAAAAAZipFLz3XoakCEQB3PVPyHJVi1iYkAAKQAZQGpQGZESInRnCFMqLDla2
207 oGgAADQGgAANNANAAAAAAZipFLz3XoakCEQB3PVPyHJVi1iYkAAKQAZQGpQGZESInRnCFMqLDla2
191 Bx3qfRQeA2N4lnzKkAmP8kR2asievLLXXebVU8Vg4iEBqcJNJAxIapSU6SM4888ZAciRG6MYAIEE
208 Bx3qfRQeA2N4lnzKkAmP8kR2asievLLXXebVU8Vg4iEBqcJNJAxIapSU6SM4888ZAciRG6MYAIEE
192 SlIBpFisgGkyRjX//TMtfcUAEsGu56+YnE1OlTZmzKm8BSu2rvo4rHAYYaadIFFuTy0LYgIkgLVD
209 SlIBpFisgGkyRjX//TMtfcUAEsGu56+YnE1OlTZmzKm8BSu2rvo4rHAYYaadIFFuTy0LYgIkgLVD
193 sgVa2F19D1tx9+hgbAygLgQwaIqcDdgA4BjQgIiz/AEP72++llgDKhKducqodGE4B0ETqF3JFOFC
210 sgVa2F19D1tx9+hgbAygLgQwaIqcDdgA4BjQgIiz/AEP72++llgDKhKducqodGE4B0ETqF3JFOFC
194 Q70eyNw=
211 Q70eyNw=
195 --===
212 --===
196
213
197 utf-8 patch:
214 utf-8 patch:
198 $ python -c 'fp = open("utf", "wb"); fp.write("h\xC3\xB6mma!\n"); fp.close();'
215 $ python -c 'fp = open("utf", "wb"); fp.write("h\xC3\xB6mma!\n"); fp.close();'
199 $ hg commit -A -d '4 0' -m 'charset=utf-8; content-transfer-encoding: base64'
216 $ hg commit -A -d '4 0' -m 'charset=utf-8; content-transfer-encoding: base64'
200 adding description
217 adding description
201 adding utf
218 adding utf
202
219
203 no mime encoding for email --test:
220 no mime encoding for email --test:
204 $ hg email --date '1970-1-1 0:4' -f quux -t foo -c bar -r tip -n | fixheaders > mailtest
221 $ hg email --date '1970-1-1 0:4' -f quux -t foo -c bar -r tip -n | fixheaders > mailtest
205
222
206 md5sum of 8-bit output:
223 md5sum of 8-bit output:
207 $ $TESTDIR/md5sum.py mailtest
224 $ $TESTDIR/md5sum.py mailtest
208 e726c29b3008e77994c7572563e57c34 mailtest
225 e726c29b3008e77994c7572563e57c34 mailtest
209
226
210 $ rm mailtest
227 $ rm mailtest
211
228
212 mime encoded mbox (base64):
229 mime encoded mbox (base64):
213 $ hg email --date '1970-1-1 0:4' -f quux -t foo -c bar -r tip -m mbox
230 $ hg email --date '1970-1-1 0:4' -f quux -t foo -c bar -r tip -m mbox
214 This patch series consists of 1 patches.
231 This patch series consists of 1 patches.
215
232
216
233
217 Writing [PATCH] charset=utf-8; content-transfer-encoding: base64 ...
234 Writing [PATCH] charset=utf-8; content-transfer-encoding: base64 ...
218
235
219 $ cat mbox
236 $ cat mbox
220 From quux Thu Jan 01 00:04:01 1970
237 From quux Thu Jan 01 00:04:01 1970
221 Content-Type: text/plain; charset="utf-8"
238 Content-Type: text/plain; charset="utf-8"
222 MIME-Version: 1.0
239 MIME-Version: 1.0
223 Content-Transfer-Encoding: base64
240 Content-Transfer-Encoding: base64
224 Subject: [PATCH] charset=utf-8; content-transfer-encoding: base64
241 Subject: [PATCH] charset=utf-8; content-transfer-encoding: base64
225 X-Mercurial-Node: c3c9e37db9f4fe4882cda39baf42fed6bad8b15a
242 X-Mercurial-Node: c3c9e37db9f4fe4882cda39baf42fed6bad8b15a
226 Message-Id: <c3c9e37db9f4fe4882cd.240@.*
243 Message-Id: <c3c9e37db9f4fe4882cd.240@.*
227 User-Agent: Mercurial-patchbomb/.*
244 User-Agent: Mercurial-patchbomb/.*
228 Date: Thu, 01 Jan 1970 00:04:00 +0000
245 Date: Thu, 01 Jan 1970 00:04:00 +0000
229 From: quux
246 From: quux
230 To: foo
247 To: foo
231 Cc: bar
248 Cc: bar
232
249
233 IyBIRyBjaGFuZ2VzZXQgcGF0Y2gKIyBVc2VyIHRlc3QKIyBEYXRlIDQgMAojIE5vZGUgSUQgYzNj
250 IyBIRyBjaGFuZ2VzZXQgcGF0Y2gKIyBVc2VyIHRlc3QKIyBEYXRlIDQgMAojIE5vZGUgSUQgYzNj
234 OWUzN2RiOWY0ZmU0ODgyY2RhMzliYWY0MmZlZDZiYWQ4YjE1YQojIFBhcmVudCAgZmYyYzlmYTIw
251 OWUzN2RiOWY0ZmU0ODgyY2RhMzliYWY0MmZlZDZiYWQ4YjE1YQojIFBhcmVudCAgZmYyYzlmYTIw
235 MThiMTVmYTc0YjMzMzYzYmRhOTUyNzMyM2UyYTk5ZgpjaGFyc2V0PXV0Zi04OyBjb250ZW50LXRy
252 MThiMTVmYTc0YjMzMzYzYmRhOTUyNzMyM2UyYTk5ZgpjaGFyc2V0PXV0Zi04OyBjb250ZW50LXRy
236 YW5zZmVyLWVuY29kaW5nOiBiYXNlNjQKCmRpZmYgLXIgZmYyYzlmYTIwMThiIC1yIGMzYzllMzdk
253 YW5zZmVyLWVuY29kaW5nOiBiYXNlNjQKCmRpZmYgLXIgZmYyYzlmYTIwMThiIC1yIGMzYzllMzdk
237 YjlmNCBkZXNjcmlwdGlvbgotLS0gL2Rldi9udWxsCVRodSBKYW4gMDEgMDA6MDA6MDAgMTk3MCAr
254 YjlmNCBkZXNjcmlwdGlvbgotLS0gL2Rldi9udWxsCVRodSBKYW4gMDEgMDA6MDA6MDAgMTk3MCAr
238 MDAwMAorKysgYi9kZXNjcmlwdGlvbglUaHUgSmFuIDAxIDAwOjAwOjA0IDE5NzAgKzAwMDAKQEAg
255 MDAwMAorKysgYi9kZXNjcmlwdGlvbglUaHUgSmFuIDAxIDAwOjAwOjA0IDE5NzAgKzAwMDAKQEAg
239 LTAsMCArMSwzIEBACithIG11bHRpbGluZQorCitkZXNjcmlwdGlvbgpkaWZmIC1yIGZmMmM5ZmEy
256 LTAsMCArMSwzIEBACithIG11bHRpbGluZQorCitkZXNjcmlwdGlvbgpkaWZmIC1yIGZmMmM5ZmEy
240 MDE4YiAtciBjM2M5ZTM3ZGI5ZjQgdXRmCi0tLSAvZGV2L251bGwJVGh1IEphbiAwMSAwMDowMDow
257 MDE4YiAtciBjM2M5ZTM3ZGI5ZjQgdXRmCi0tLSAvZGV2L251bGwJVGh1IEphbiAwMSAwMDowMDow
241 MCAxOTcwICswMDAwCisrKyBiL3V0ZglUaHUgSmFuIDAxIDAwOjAwOjA0IDE5NzAgKzAwMDAKQEAg
258 MCAxOTcwICswMDAwCisrKyBiL3V0ZglUaHUgSmFuIDAxIDAwOjAwOjA0IDE5NzAgKzAwMDAKQEAg
242 LTAsMCArMSwxIEBACitow7ZtbWEhCg==
259 LTAsMCArMSwxIEBACitow7ZtbWEhCg==
243
260
244
261
245 $ rm mbox
262 $ rm mbox
246
263
247 mime encoded mbox (quoted-printable):
264 mime encoded mbox (quoted-printable):
248 $ python -c 'fp = open("qp", "wb"); fp.write("%s\nfoo\n\nbar\n" % ("x" * 1024)); fp.close();'
265 $ python -c 'fp = open("qp", "wb"); fp.write("%s\nfoo\n\nbar\n" % ("x" * 1024)); fp.close();'
249 $ hg commit -A -d '4 0' -m 'charset=utf-8; content-transfer-encoding: quoted-printable'
266 $ hg commit -A -d '4 0' -m 'charset=utf-8; content-transfer-encoding: quoted-printable'
250 adding qp
267 adding qp
251
268
252 no mime encoding for email --test:
269 no mime encoding for email --test:
253 $ hg email --date '1970-1-1 0:4' -f quux -t foo -c bar -r tip -n | \
270 $ hg email --date '1970-1-1 0:4' -f quux -t foo -c bar -r tip -n | \
254 > fixheaders > mailtest
271 > fixheaders > mailtest
255 md5sum of qp output:
272 md5sum of qp output:
256 $ $TESTDIR/md5sum.py mailtest
273 $ $TESTDIR/md5sum.py mailtest
257 0402c7d033e04044e423bb04816f9dae mailtest
274 0402c7d033e04044e423bb04816f9dae mailtest
258 $ rm mailtest
275 $ rm mailtest
259
276
260 mime encoded mbox (quoted-printable):
277 mime encoded mbox (quoted-printable):
261 $ hg email --date '1970-1-1 0:4' -f quux -t foo -c bar -r tip -m mbox
278 $ hg email --date '1970-1-1 0:4' -f quux -t foo -c bar -r tip -m mbox
262 This patch series consists of 1 patches.
279 This patch series consists of 1 patches.
263
280
264
281
265 Writing [PATCH] charset=utf-8; content-transfer-encoding: quoted-printable ...
282 Writing [PATCH] charset=utf-8; content-transfer-encoding: quoted-printable ...
266 $ cat mbox | fixheaders
283 $ cat mbox | fixheaders
267 From quux Thu Jan 01 00:04:01 1970
284 From quux Thu Jan 01 00:04:01 1970
268 Content-Type: text/plain; charset="us-ascii"
285 Content-Type: text/plain; charset="us-ascii"
269 MIME-Version: 1.0
286 MIME-Version: 1.0
270 Content-Transfer-Encoding: quoted-printable
287 Content-Transfer-Encoding: quoted-printable
271 Subject: [PATCH] charset=utf-8; content-transfer-encoding: quoted-printable
288 Subject: [PATCH] charset=utf-8; content-transfer-encoding: quoted-printable
272 X-Mercurial-Node: c655633f8c87700bb38cc6a59a2753bdc5a6c376
289 X-Mercurial-Node: c655633f8c87700bb38cc6a59a2753bdc5a6c376
273 Message-Id: <c655633f8c87700bb38c.240@
290 Message-Id: <c655633f8c87700bb38c.240@
274 User-Agent: Mercurial-patchbomb
291 User-Agent: Mercurial-patchbomb
275 Date: Thu, 01 Jan 1970 00:04:00 +0000
292 Date: Thu, 01 Jan 1970 00:04:00 +0000
276 From: quux
293 From: quux
277 To: foo
294 To: foo
278 Cc: bar
295 Cc: bar
279
296
280 # HG changeset patch
297 # HG changeset patch
281 # User test
298 # User test
282 # Date 4 0
299 # Date 4 0
283 # Node ID c655633f8c87700bb38cc6a59a2753bdc5a6c376
300 # Node ID c655633f8c87700bb38cc6a59a2753bdc5a6c376
284 # Parent c3c9e37db9f4fe4882cda39baf42fed6bad8b15a
301 # Parent c3c9e37db9f4fe4882cda39baf42fed6bad8b15a
285 charset=3Dutf-8; content-transfer-encoding: quoted-printable
302 charset=3Dutf-8; content-transfer-encoding: quoted-printable
286
303
287 diff -r c3c9e37db9f4 -r c655633f8c87 qp
304 diff -r c3c9e37db9f4 -r c655633f8c87 qp
288 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
305 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
289 +++ b/qp Thu Jan 01 00:00:04 1970 +0000
306 +++ b/qp Thu Jan 01 00:00:04 1970 +0000
290 @@ -0,0 +1,4 @@
307 @@ -0,0 +1,4 @@
291 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
308 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
292 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
309 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
293 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
310 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
294 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
311 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
295 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
312 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
296 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
313 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
297 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
314 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
298 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
315 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
299 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
316 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
300 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
317 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
301 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
318 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
302 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
319 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
303 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
320 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
304 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
321 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
305 +foo
322 +foo
306 +
323 +
307 +bar
324 +bar
308
325
309
326
310
327
311 $ rm mbox
328 $ rm mbox
312
329
313 iso-8859-1 patch:
330 iso-8859-1 patch:
314 $ python -c 'fp = open("isolatin", "wb"); fp.write("h\xF6mma!\n"); fp.close();'
331 $ python -c 'fp = open("isolatin", "wb"); fp.write("h\xF6mma!\n"); fp.close();'
315 $ hg commit -A -d '5 0' -m 'charset=us-ascii; content-transfer-encoding: 8bit'
332 $ hg commit -A -d '5 0' -m 'charset=us-ascii; content-transfer-encoding: 8bit'
316 adding isolatin
333 adding isolatin
317
334
318 fake ascii mbox:
335 fake ascii mbox:
319 $ hg email --date '1970-1-1 0:5' -f quux -t foo -c bar -r tip -m mbox
336 $ hg email --date '1970-1-1 0:5' -f quux -t foo -c bar -r tip -m mbox
320 This patch series consists of 1 patches.
337 This patch series consists of 1 patches.
321
338
322
339
323 Writing [PATCH] charset=us-ascii; content-transfer-encoding: 8bit ...
340 Writing [PATCH] charset=us-ascii; content-transfer-encoding: 8bit ...
324 $ fixheaders < mbox > mboxfix
341 $ fixheaders < mbox > mboxfix
325
342
326 md5sum of 8-bit output:
343 md5sum of 8-bit output:
327 $ $TESTDIR/md5sum.py mboxfix
344 $ $TESTDIR/md5sum.py mboxfix
328 9ea043d8fc43a71045114508baed144b mboxfix
345 9ea043d8fc43a71045114508baed144b mboxfix
329
346
330 test diffstat for single patch:
347 test diffstat for single patch:
331 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -d -y -r 2 | \
348 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -d -y -r 2 | \
332 > fixheaders
349 > fixheaders
333 This patch series consists of 1 patches.
350 This patch series consists of 1 patches.
334
351
335
352
336 Final summary:
353 Final summary:
337
354
338 From: quux
355 From: quux
339 To: foo
356 To: foo
340 Cc: bar
357 Cc: bar
341 Subject: [PATCH] test
358 Subject: [PATCH] test
342 c | 1 +
359 c | 1 +
343 1 files changed, 1 insertions(+), 0 deletions(-)
360 1 files changed, 1 insertions(+), 0 deletions(-)
344
361
345 are you sure you want to send (yn)? y
362 are you sure you want to send (yn)? y
346
363
347 Displaying [PATCH] test ...
364 Displaying [PATCH] test ...
348 Content-Type: text/plain; charset="us-ascii"
365 Content-Type: text/plain; charset="us-ascii"
349 MIME-Version: 1.0
366 MIME-Version: 1.0
350 Content-Transfer-Encoding: 7bit
367 Content-Transfer-Encoding: 7bit
351 Subject: [PATCH] test
368 Subject: [PATCH] test
352 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
369 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
353 Message-Id: <ff2c9fa2018b15fa74b3.60@
370 Message-Id: <ff2c9fa2018b15fa74b3.60@
354 User-Agent: Mercurial-patchbomb
371 User-Agent: Mercurial-patchbomb
355 Date: Thu, 01 Jan 1970 00:01:00 +0000
372 Date: Thu, 01 Jan 1970 00:01:00 +0000
356 From: quux
373 From: quux
357 To: foo
374 To: foo
358 Cc: bar
375 Cc: bar
359
376
360 c | 1 +
377 c | 1 +
361 1 files changed, 1 insertions(+), 0 deletions(-)
378 1 files changed, 1 insertions(+), 0 deletions(-)
362
379
363
380
364 # HG changeset patch
381 # HG changeset patch
365 # User test
382 # User test
366 # Date 3 0
383 # Date 3 0
367 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
384 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
368 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
385 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
369 c
386 c
370
387
371 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
388 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
372 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
389 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
373 +++ b/c Thu Jan 01 00:00:03 1970 +0000
390 +++ b/c Thu Jan 01 00:00:03 1970 +0000
374 @@ -0,0 +1,1 @@
391 @@ -0,0 +1,1 @@
375 +c
392 +c
376
393
377
394
378 test diffstat for multiple patches:
395 test diffstat for multiple patches:
379 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -d -y \
396 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -d -y \
380 > -r 0:1 | fixheaders
397 > -r 0:1 | fixheaders
381 This patch series consists of 2 patches.
398 This patch series consists of 2 patches.
382
399
383
400
384 Write the introductory message for the patch series.
401 Write the introductory message for the patch series.
385
402
386
403
387 Final summary:
404 Final summary:
388
405
389 From: quux
406 From: quux
390 To: foo
407 To: foo
391 Cc: bar
408 Cc: bar
392 Subject: [PATCH 0 of 2] test
409 Subject: [PATCH 0 of 2] test
393 a | 1 +
410 a | 1 +
394 b | 1 +
411 b | 1 +
395 2 files changed, 2 insertions(+), 0 deletions(-)
412 2 files changed, 2 insertions(+), 0 deletions(-)
396 Subject: [PATCH 1 of 2] a
413 Subject: [PATCH 1 of 2] a
397 a | 1 +
414 a | 1 +
398 1 files changed, 1 insertions(+), 0 deletions(-)
415 1 files changed, 1 insertions(+), 0 deletions(-)
399 Subject: [PATCH 2 of 2] b
416 Subject: [PATCH 2 of 2] b
400 b | 1 +
417 b | 1 +
401 1 files changed, 1 insertions(+), 0 deletions(-)
418 1 files changed, 1 insertions(+), 0 deletions(-)
402
419
403 are you sure you want to send (yn)? y
420 are you sure you want to send (yn)? y
404
421
405 Displaying [PATCH 0 of 2] test ...
422 Displaying [PATCH 0 of 2] test ...
406 Content-Type: text/plain; charset="us-ascii"
423 Content-Type: text/plain; charset="us-ascii"
407 MIME-Version: 1.0
424 MIME-Version: 1.0
408 Content-Transfer-Encoding: 7bit
425 Content-Transfer-Encoding: 7bit
409 Subject: [PATCH 0 of 2] test
426 Subject: [PATCH 0 of 2] test
410 Message-Id: <patchbomb.60@
427 Message-Id: <patchbomb.60@
411 User-Agent: Mercurial-patchbomb
428 User-Agent: Mercurial-patchbomb
412 Date: Thu, 01 Jan 1970 00:01:00 +0000
429 Date: Thu, 01 Jan 1970 00:01:00 +0000
413 From: quux
430 From: quux
414 To: foo
431 To: foo
415 Cc: bar
432 Cc: bar
416
433
417
434
418 a | 1 +
435 a | 1 +
419 b | 1 +
436 b | 1 +
420 2 files changed, 2 insertions(+), 0 deletions(-)
437 2 files changed, 2 insertions(+), 0 deletions(-)
421
438
422 Displaying [PATCH 1 of 2] a ...
439 Displaying [PATCH 1 of 2] a ...
423 Content-Type: text/plain; charset="us-ascii"
440 Content-Type: text/plain; charset="us-ascii"
424 MIME-Version: 1.0
441 MIME-Version: 1.0
425 Content-Transfer-Encoding: 7bit
442 Content-Transfer-Encoding: 7bit
426 Subject: [PATCH 1 of 2] a
443 Subject: [PATCH 1 of 2] a
427 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
444 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
428 Message-Id: <8580ff50825a50c8f716.61@
445 Message-Id: <8580ff50825a50c8f716.61@
429 In-Reply-To: <patchbomb.60@
446 In-Reply-To: <patchbomb.60@
430 References: <patchbomb.60@
447 References: <patchbomb.60@
431 User-Agent: Mercurial-patchbomb
448 User-Agent: Mercurial-patchbomb
432 Date: Thu, 01 Jan 1970 00:01:01 +0000
449 Date: Thu, 01 Jan 1970 00:01:01 +0000
433 From: quux
450 From: quux
434 To: foo
451 To: foo
435 Cc: bar
452 Cc: bar
436
453
437 a | 1 +
454 a | 1 +
438 1 files changed, 1 insertions(+), 0 deletions(-)
455 1 files changed, 1 insertions(+), 0 deletions(-)
439
456
440
457
441 # HG changeset patch
458 # HG changeset patch
442 # User test
459 # User test
443 # Date 1 0
460 # Date 1 0
444 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
461 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
445 # Parent 0000000000000000000000000000000000000000
462 # Parent 0000000000000000000000000000000000000000
446 a
463 a
447
464
448 diff -r 000000000000 -r 8580ff50825a a
465 diff -r 000000000000 -r 8580ff50825a a
449 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
466 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
450 +++ b/a Thu Jan 01 00:00:01 1970 +0000
467 +++ b/a Thu Jan 01 00:00:01 1970 +0000
451 @@ -0,0 +1,1 @@
468 @@ -0,0 +1,1 @@
452 +a
469 +a
453
470
454 Displaying [PATCH 2 of 2] b ...
471 Displaying [PATCH 2 of 2] b ...
455 Content-Type: text/plain; charset="us-ascii"
472 Content-Type: text/plain; charset="us-ascii"
456 MIME-Version: 1.0
473 MIME-Version: 1.0
457 Content-Transfer-Encoding: 7bit
474 Content-Transfer-Encoding: 7bit
458 Subject: [PATCH 2 of 2] b
475 Subject: [PATCH 2 of 2] b
459 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
476 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
460 Message-Id: <97d72e5f12c7e84f8506.62@
477 Message-Id: <97d72e5f12c7e84f8506.62@
461 In-Reply-To: <patchbomb.60@
478 In-Reply-To: <patchbomb.60@
462 References: <patchbomb.60@
479 References: <patchbomb.60@
463 User-Agent: Mercurial-patchbomb
480 User-Agent: Mercurial-patchbomb
464 Date: Thu, 01 Jan 1970 00:01:02 +0000
481 Date: Thu, 01 Jan 1970 00:01:02 +0000
465 From: quux
482 From: quux
466 To: foo
483 To: foo
467 Cc: bar
484 Cc: bar
468
485
469 b | 1 +
486 b | 1 +
470 1 files changed, 1 insertions(+), 0 deletions(-)
487 1 files changed, 1 insertions(+), 0 deletions(-)
471
488
472
489
473 # HG changeset patch
490 # HG changeset patch
474 # User test
491 # User test
475 # Date 2 0
492 # Date 2 0
476 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
493 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
477 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
494 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
478 b
495 b
479
496
480 diff -r 8580ff50825a -r 97d72e5f12c7 b
497 diff -r 8580ff50825a -r 97d72e5f12c7 b
481 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
498 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
482 +++ b/b Thu Jan 01 00:00:02 1970 +0000
499 +++ b/b Thu Jan 01 00:00:02 1970 +0000
483 @@ -0,0 +1,1 @@
500 @@ -0,0 +1,1 @@
484 +b
501 +b
485
502
486
503
487 test inline for single patch:
504 test inline for single patch:
488 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -i -r 2 | \
505 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -i -r 2 | \
489 > fixheaders
506 > fixheaders
490 This patch series consists of 1 patches.
507 This patch series consists of 1 patches.
491
508
492
509
493 Displaying [PATCH] test ...
510 Displaying [PATCH] test ...
494 Content-Type: multipart/mixed; boundary="===
511 Content-Type: multipart/mixed; boundary="===
495 MIME-Version: 1.0
512 MIME-Version: 1.0
496 Subject: [PATCH] test
513 Subject: [PATCH] test
497 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
514 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
498 Message-Id: <ff2c9fa2018b15fa74b3.60@
515 Message-Id: <ff2c9fa2018b15fa74b3.60@
499 User-Agent: Mercurial-patchbomb
516 User-Agent: Mercurial-patchbomb
500 Date: Thu, 01 Jan 1970 00:01:00 +0000
517 Date: Thu, 01 Jan 1970 00:01:00 +0000
501 From: quux
518 From: quux
502 To: foo
519 To: foo
503 Cc: bar
520 Cc: bar
504
521
505 --===
522 --===
506 Content-Type: text/x-patch; charset="us-ascii"
523 Content-Type: text/x-patch; charset="us-ascii"
507 MIME-Version: 1.0
524 MIME-Version: 1.0
508 Content-Transfer-Encoding: 7bit
525 Content-Transfer-Encoding: 7bit
509 Content-Disposition: inline; filename=t2.patch
526 Content-Disposition: inline; filename=t2.patch
510
527
511 # HG changeset patch
528 # HG changeset patch
512 # User test
529 # User test
513 # Date 3 0
530 # Date 3 0
514 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
531 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
515 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
532 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
516 c
533 c
517
534
518 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
535 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
519 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
536 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
520 +++ b/c Thu Jan 01 00:00:03 1970 +0000
537 +++ b/c Thu Jan 01 00:00:03 1970 +0000
521 @@ -0,0 +1,1 @@
538 @@ -0,0 +1,1 @@
522 +c
539 +c
523
540
524 --===
541 --===
525
542
526
543
527 test inline for single patch (quoted-printable):
544 test inline for single patch (quoted-printable):
528 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -i -r 4 | \
545 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -i -r 4 | \
529 > fixheaders
546 > fixheaders
530 This patch series consists of 1 patches.
547 This patch series consists of 1 patches.
531
548
532
549
533 Displaying [PATCH] test ...
550 Displaying [PATCH] test ...
534 Content-Type: multipart/mixed; boundary="===
551 Content-Type: multipart/mixed; boundary="===
535 MIME-Version: 1.0
552 MIME-Version: 1.0
536 Subject: [PATCH] test
553 Subject: [PATCH] test
537 X-Mercurial-Node: c655633f8c87700bb38cc6a59a2753bdc5a6c376
554 X-Mercurial-Node: c655633f8c87700bb38cc6a59a2753bdc5a6c376
538 Message-Id: <c655633f8c87700bb38c.60@
555 Message-Id: <c655633f8c87700bb38c.60@
539 User-Agent: Mercurial-patchbomb
556 User-Agent: Mercurial-patchbomb
540 Date: Thu, 01 Jan 1970 00:01:00 +0000
557 Date: Thu, 01 Jan 1970 00:01:00 +0000
541 From: quux
558 From: quux
542 To: foo
559 To: foo
543 Cc: bar
560 Cc: bar
544
561
545 --===
562 --===
546 Content-Type: text/x-patch; charset="us-ascii"
563 Content-Type: text/x-patch; charset="us-ascii"
547 MIME-Version: 1.0
564 MIME-Version: 1.0
548 Content-Transfer-Encoding: quoted-printable
565 Content-Transfer-Encoding: quoted-printable
549 Content-Disposition: inline; filename=t2.patch
566 Content-Disposition: inline; filename=t2.patch
550
567
551 # HG changeset patch
568 # HG changeset patch
552 # User test
569 # User test
553 # Date 4 0
570 # Date 4 0
554 # Node ID c655633f8c87700bb38cc6a59a2753bdc5a6c376
571 # Node ID c655633f8c87700bb38cc6a59a2753bdc5a6c376
555 # Parent c3c9e37db9f4fe4882cda39baf42fed6bad8b15a
572 # Parent c3c9e37db9f4fe4882cda39baf42fed6bad8b15a
556 charset=3Dutf-8; content-transfer-encoding: quoted-printable
573 charset=3Dutf-8; content-transfer-encoding: quoted-printable
557
574
558 diff -r c3c9e37db9f4 -r c655633f8c87 qp
575 diff -r c3c9e37db9f4 -r c655633f8c87 qp
559 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
576 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
560 +++ b/qp Thu Jan 01 00:00:04 1970 +0000
577 +++ b/qp Thu Jan 01 00:00:04 1970 +0000
561 @@ -0,0 +1,4 @@
578 @@ -0,0 +1,4 @@
562 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
579 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
563 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
580 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
564 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
581 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
565 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
582 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
566 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
583 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
567 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
584 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
568 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
585 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
569 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
586 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
570 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
587 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
571 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
588 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
572 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
589 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
573 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
590 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
574 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
591 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
575 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
592 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
576 +foo
593 +foo
577 +
594 +
578 +bar
595 +bar
579
596
580 --===
597 --===
581
598
582 test inline for multiple patches:
599 test inline for multiple patches:
583 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -i \
600 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -i \
584 > -r 0:1 -r 4 | fixheaders
601 > -r 0:1 -r 4 | fixheaders
585 This patch series consists of 3 patches.
602 This patch series consists of 3 patches.
586
603
587
604
588 Write the introductory message for the patch series.
605 Write the introductory message for the patch series.
589
606
590
607
591 Displaying [PATCH 0 of 3] test ...
608 Displaying [PATCH 0 of 3] test ...
592 Content-Type: text/plain; charset="us-ascii"
609 Content-Type: text/plain; charset="us-ascii"
593 MIME-Version: 1.0
610 MIME-Version: 1.0
594 Content-Transfer-Encoding: 7bit
611 Content-Transfer-Encoding: 7bit
595 Subject: [PATCH 0 of 3] test
612 Subject: [PATCH 0 of 3] test
596 Message-Id: <patchbomb.60@
613 Message-Id: <patchbomb.60@
597 User-Agent: Mercurial-patchbomb
614 User-Agent: Mercurial-patchbomb
598 Date: Thu, 01 Jan 1970 00:01:00 +0000
615 Date: Thu, 01 Jan 1970 00:01:00 +0000
599 From: quux
616 From: quux
600 To: foo
617 To: foo
601 Cc: bar
618 Cc: bar
602
619
603
620
604 Displaying [PATCH 1 of 3] a ...
621 Displaying [PATCH 1 of 3] a ...
605 Content-Type: multipart/mixed; boundary="===
622 Content-Type: multipart/mixed; boundary="===
606 MIME-Version: 1.0
623 MIME-Version: 1.0
607 Subject: [PATCH 1 of 3] a
624 Subject: [PATCH 1 of 3] a
608 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
625 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
609 Message-Id: <8580ff50825a50c8f716.61@
626 Message-Id: <8580ff50825a50c8f716.61@
610 In-Reply-To: <patchbomb.60@
627 In-Reply-To: <patchbomb.60@
611 References: <patchbomb.60@
628 References: <patchbomb.60@
612 User-Agent: Mercurial-patchbomb
629 User-Agent: Mercurial-patchbomb
613 Date: Thu, 01 Jan 1970 00:01:01 +0000
630 Date: Thu, 01 Jan 1970 00:01:01 +0000
614 From: quux
631 From: quux
615 To: foo
632 To: foo
616 Cc: bar
633 Cc: bar
617
634
618 --===
635 --===
619 Content-Type: text/x-patch; charset="us-ascii"
636 Content-Type: text/x-patch; charset="us-ascii"
620 MIME-Version: 1.0
637 MIME-Version: 1.0
621 Content-Transfer-Encoding: 7bit
638 Content-Transfer-Encoding: 7bit
622 Content-Disposition: inline; filename=t2-1.patch
639 Content-Disposition: inline; filename=t2-1.patch
623
640
624 # HG changeset patch
641 # HG changeset patch
625 # User test
642 # User test
626 # Date 1 0
643 # Date 1 0
627 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
644 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
628 # Parent 0000000000000000000000000000000000000000
645 # Parent 0000000000000000000000000000000000000000
629 a
646 a
630
647
631 diff -r 000000000000 -r 8580ff50825a a
648 diff -r 000000000000 -r 8580ff50825a a
632 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
649 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
633 +++ b/a Thu Jan 01 00:00:01 1970 +0000
650 +++ b/a Thu Jan 01 00:00:01 1970 +0000
634 @@ -0,0 +1,1 @@
651 @@ -0,0 +1,1 @@
635 +a
652 +a
636
653
637 --===
654 --===
638 Displaying [PATCH 2 of 3] b ...
655 Displaying [PATCH 2 of 3] b ...
639 Content-Type: multipart/mixed; boundary="===
656 Content-Type: multipart/mixed; boundary="===
640 MIME-Version: 1.0
657 MIME-Version: 1.0
641 Subject: [PATCH 2 of 3] b
658 Subject: [PATCH 2 of 3] b
642 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
659 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
643 Message-Id: <97d72e5f12c7e84f8506.62@
660 Message-Id: <97d72e5f12c7e84f8506.62@
644 In-Reply-To: <patchbomb.60@
661 In-Reply-To: <patchbomb.60@
645 References: <patchbomb.60@
662 References: <patchbomb.60@
646 User-Agent: Mercurial-patchbomb
663 User-Agent: Mercurial-patchbomb
647 Date: Thu, 01 Jan 1970 00:01:02 +0000
664 Date: Thu, 01 Jan 1970 00:01:02 +0000
648 From: quux
665 From: quux
649 To: foo
666 To: foo
650 Cc: bar
667 Cc: bar
651
668
652 --===
669 --===
653 Content-Type: text/x-patch; charset="us-ascii"
670 Content-Type: text/x-patch; charset="us-ascii"
654 MIME-Version: 1.0
671 MIME-Version: 1.0
655 Content-Transfer-Encoding: 7bit
672 Content-Transfer-Encoding: 7bit
656 Content-Disposition: inline; filename=t2-2.patch
673 Content-Disposition: inline; filename=t2-2.patch
657
674
658 # HG changeset patch
675 # HG changeset patch
659 # User test
676 # User test
660 # Date 2 0
677 # Date 2 0
661 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
678 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
662 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
679 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
663 b
680 b
664
681
665 diff -r 8580ff50825a -r 97d72e5f12c7 b
682 diff -r 8580ff50825a -r 97d72e5f12c7 b
666 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
683 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
667 +++ b/b Thu Jan 01 00:00:02 1970 +0000
684 +++ b/b Thu Jan 01 00:00:02 1970 +0000
668 @@ -0,0 +1,1 @@
685 @@ -0,0 +1,1 @@
669 +b
686 +b
670
687
671 --===
688 --===
672 Displaying [PATCH 3 of 3] charset=utf-8; content-transfer-encoding: quoted-printable ...
689 Displaying [PATCH 3 of 3] charset=utf-8; content-transfer-encoding: quoted-printable ...
673 Content-Type: multipart/mixed; boundary="===
690 Content-Type: multipart/mixed; boundary="===
674 MIME-Version: 1.0
691 MIME-Version: 1.0
675 Subject: [PATCH 3 of 3] charset=utf-8;
692 Subject: [PATCH 3 of 3] charset=utf-8;
676 content-transfer-encoding: quoted-printable
693 content-transfer-encoding: quoted-printable
677 X-Mercurial-Node: c655633f8c87700bb38cc6a59a2753bdc5a6c376
694 X-Mercurial-Node: c655633f8c87700bb38cc6a59a2753bdc5a6c376
678 Message-Id: <c655633f8c87700bb38c.63@
695 Message-Id: <c655633f8c87700bb38c.63@
679 In-Reply-To: <patchbomb.60@
696 In-Reply-To: <patchbomb.60@
680 References: <patchbomb.60@
697 References: <patchbomb.60@
681 User-Agent: Mercurial-patchbomb
698 User-Agent: Mercurial-patchbomb
682 Date: Thu, 01 Jan 1970 00:01:03 +0000
699 Date: Thu, 01 Jan 1970 00:01:03 +0000
683 From: quux
700 From: quux
684 To: foo
701 To: foo
685 Cc: bar
702 Cc: bar
686
703
687 --===
704 --===
688 Content-Type: text/x-patch; charset="us-ascii"
705 Content-Type: text/x-patch; charset="us-ascii"
689 MIME-Version: 1.0
706 MIME-Version: 1.0
690 Content-Transfer-Encoding: quoted-printable
707 Content-Transfer-Encoding: quoted-printable
691 Content-Disposition: inline; filename=t2-3.patch
708 Content-Disposition: inline; filename=t2-3.patch
692
709
693 # HG changeset patch
710 # HG changeset patch
694 # User test
711 # User test
695 # Date 4 0
712 # Date 4 0
696 # Node ID c655633f8c87700bb38cc6a59a2753bdc5a6c376
713 # Node ID c655633f8c87700bb38cc6a59a2753bdc5a6c376
697 # Parent c3c9e37db9f4fe4882cda39baf42fed6bad8b15a
714 # Parent c3c9e37db9f4fe4882cda39baf42fed6bad8b15a
698 charset=3Dutf-8; content-transfer-encoding: quoted-printable
715 charset=3Dutf-8; content-transfer-encoding: quoted-printable
699
716
700 diff -r c3c9e37db9f4 -r c655633f8c87 qp
717 diff -r c3c9e37db9f4 -r c655633f8c87 qp
701 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
718 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
702 +++ b/qp Thu Jan 01 00:00:04 1970 +0000
719 +++ b/qp Thu Jan 01 00:00:04 1970 +0000
703 @@ -0,0 +1,4 @@
720 @@ -0,0 +1,4 @@
704 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
721 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
705 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
722 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
706 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
723 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
707 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
724 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
708 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
725 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
709 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
726 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
710 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
727 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
711 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
728 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
712 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
729 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
713 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
730 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
714 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
731 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
715 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
732 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
716 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
733 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
717 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
734 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
718 +foo
735 +foo
719 +
736 +
720 +bar
737 +bar
721
738
722 --===
739 --===
723
740
724 test attach for single patch:
741 test attach for single patch:
725 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -a -r 2 | \
742 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -a -r 2 | \
726 > fixheaders
743 > fixheaders
727 This patch series consists of 1 patches.
744 This patch series consists of 1 patches.
728
745
729
746
730 Displaying [PATCH] test ...
747 Displaying [PATCH] test ...
731 Content-Type: multipart/mixed; boundary="===
748 Content-Type: multipart/mixed; boundary="===
732 MIME-Version: 1.0
749 MIME-Version: 1.0
733 Subject: [PATCH] test
750 Subject: [PATCH] test
734 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
751 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
735 Message-Id: <ff2c9fa2018b15fa74b3.60@
752 Message-Id: <ff2c9fa2018b15fa74b3.60@
736 User-Agent: Mercurial-patchbomb
753 User-Agent: Mercurial-patchbomb
737 Date: Thu, 01 Jan 1970 00:01:00 +0000
754 Date: Thu, 01 Jan 1970 00:01:00 +0000
738 From: quux
755 From: quux
739 To: foo
756 To: foo
740 Cc: bar
757 Cc: bar
741
758
742 --===
759 --===
743 Content-Type: text/plain; charset="us-ascii"
760 Content-Type: text/plain; charset="us-ascii"
744 MIME-Version: 1.0
761 MIME-Version: 1.0
745 Content-Transfer-Encoding: 7bit
762 Content-Transfer-Encoding: 7bit
746
763
747 Patch subject is complete summary.
764 Patch subject is complete summary.
748
765
749
766
750
767
751 --===
768 --===
752 Content-Type: text/x-patch; charset="us-ascii"
769 Content-Type: text/x-patch; charset="us-ascii"
753 MIME-Version: 1.0
770 MIME-Version: 1.0
754 Content-Transfer-Encoding: 7bit
771 Content-Transfer-Encoding: 7bit
755 Content-Disposition: attachment; filename=t2.patch
772 Content-Disposition: attachment; filename=t2.patch
756
773
757 # HG changeset patch
774 # HG changeset patch
758 # User test
775 # User test
759 # Date 3 0
776 # Date 3 0
760 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
777 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
761 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
778 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
762 c
779 c
763
780
764 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
781 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
765 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
782 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
766 +++ b/c Thu Jan 01 00:00:03 1970 +0000
783 +++ b/c Thu Jan 01 00:00:03 1970 +0000
767 @@ -0,0 +1,1 @@
784 @@ -0,0 +1,1 @@
768 +c
785 +c
769
786
770 --===
787 --===
771
788
772 test attach for single patch (quoted-printable):
789 test attach for single patch (quoted-printable):
773 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -a -r 4 | \
790 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -a -r 4 | \
774 > fixheaders
791 > fixheaders
775 This patch series consists of 1 patches.
792 This patch series consists of 1 patches.
776
793
777
794
778 Displaying [PATCH] test ...
795 Displaying [PATCH] test ...
779 Content-Type: multipart/mixed; boundary="===
796 Content-Type: multipart/mixed; boundary="===
780 MIME-Version: 1.0
797 MIME-Version: 1.0
781 Subject: [PATCH] test
798 Subject: [PATCH] test
782 X-Mercurial-Node: c655633f8c87700bb38cc6a59a2753bdc5a6c376
799 X-Mercurial-Node: c655633f8c87700bb38cc6a59a2753bdc5a6c376
783 Message-Id: <c655633f8c87700bb38c.60@
800 Message-Id: <c655633f8c87700bb38c.60@
784 User-Agent: Mercurial-patchbomb
801 User-Agent: Mercurial-patchbomb
785 Date: Thu, 01 Jan 1970 00:01:00 +0000
802 Date: Thu, 01 Jan 1970 00:01:00 +0000
786 From: quux
803 From: quux
787 To: foo
804 To: foo
788 Cc: bar
805 Cc: bar
789
806
790 --===
807 --===
791 Content-Type: text/plain; charset="us-ascii"
808 Content-Type: text/plain; charset="us-ascii"
792 MIME-Version: 1.0
809 MIME-Version: 1.0
793 Content-Transfer-Encoding: 7bit
810 Content-Transfer-Encoding: 7bit
794
811
795 Patch subject is complete summary.
812 Patch subject is complete summary.
796
813
797
814
798
815
799 --===
816 --===
800 Content-Type: text/x-patch; charset="us-ascii"
817 Content-Type: text/x-patch; charset="us-ascii"
801 MIME-Version: 1.0
818 MIME-Version: 1.0
802 Content-Transfer-Encoding: quoted-printable
819 Content-Transfer-Encoding: quoted-printable
803 Content-Disposition: attachment; filename=t2.patch
820 Content-Disposition: attachment; filename=t2.patch
804
821
805 # HG changeset patch
822 # HG changeset patch
806 # User test
823 # User test
807 # Date 4 0
824 # Date 4 0
808 # Node ID c655633f8c87700bb38cc6a59a2753bdc5a6c376
825 # Node ID c655633f8c87700bb38cc6a59a2753bdc5a6c376
809 # Parent c3c9e37db9f4fe4882cda39baf42fed6bad8b15a
826 # Parent c3c9e37db9f4fe4882cda39baf42fed6bad8b15a
810 charset=3Dutf-8; content-transfer-encoding: quoted-printable
827 charset=3Dutf-8; content-transfer-encoding: quoted-printable
811
828
812 diff -r c3c9e37db9f4 -r c655633f8c87 qp
829 diff -r c3c9e37db9f4 -r c655633f8c87 qp
813 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
830 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
814 +++ b/qp Thu Jan 01 00:00:04 1970 +0000
831 +++ b/qp Thu Jan 01 00:00:04 1970 +0000
815 @@ -0,0 +1,4 @@
832 @@ -0,0 +1,4 @@
816 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
833 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
817 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
834 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
818 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
835 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
819 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
836 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
820 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
837 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
821 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
838 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
822 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
839 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
823 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
840 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
824 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
841 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
825 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
842 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
826 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
843 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
827 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
844 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
828 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
845 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
829 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
846 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
830 +foo
847 +foo
831 +
848 +
832 +bar
849 +bar
833
850
834 --===
851 --===
835
852
836 test attach for multiple patches:
853 test attach for multiple patches:
837 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -a \
854 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -a \
838 > -r 0:1 -r 4 | fixheaders
855 > -r 0:1 -r 4 | fixheaders
839 This patch series consists of 3 patches.
856 This patch series consists of 3 patches.
840
857
841
858
842 Write the introductory message for the patch series.
859 Write the introductory message for the patch series.
843
860
844
861
845 Displaying [PATCH 0 of 3] test ...
862 Displaying [PATCH 0 of 3] test ...
846 Content-Type: text/plain; charset="us-ascii"
863 Content-Type: text/plain; charset="us-ascii"
847 MIME-Version: 1.0
864 MIME-Version: 1.0
848 Content-Transfer-Encoding: 7bit
865 Content-Transfer-Encoding: 7bit
849 Subject: [PATCH 0 of 3] test
866 Subject: [PATCH 0 of 3] test
850 Message-Id: <patchbomb.60@
867 Message-Id: <patchbomb.60@
851 User-Agent: Mercurial-patchbomb
868 User-Agent: Mercurial-patchbomb
852 Date: Thu, 01 Jan 1970 00:01:00 +0000
869 Date: Thu, 01 Jan 1970 00:01:00 +0000
853 From: quux
870 From: quux
854 To: foo
871 To: foo
855 Cc: bar
872 Cc: bar
856
873
857
874
858 Displaying [PATCH 1 of 3] a ...
875 Displaying [PATCH 1 of 3] a ...
859 Content-Type: multipart/mixed; boundary="===
876 Content-Type: multipart/mixed; boundary="===
860 MIME-Version: 1.0
877 MIME-Version: 1.0
861 Subject: [PATCH 1 of 3] a
878 Subject: [PATCH 1 of 3] a
862 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
879 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
863 Message-Id: <8580ff50825a50c8f716.61@
880 Message-Id: <8580ff50825a50c8f716.61@
864 In-Reply-To: <patchbomb.60@
881 In-Reply-To: <patchbomb.60@
865 References: <patchbomb.60@
882 References: <patchbomb.60@
866 User-Agent: Mercurial-patchbomb
883 User-Agent: Mercurial-patchbomb
867 Date: Thu, 01 Jan 1970 00:01:01 +0000
884 Date: Thu, 01 Jan 1970 00:01:01 +0000
868 From: quux
885 From: quux
869 To: foo
886 To: foo
870 Cc: bar
887 Cc: bar
871
888
872 --===
889 --===
873 Content-Type: text/plain; charset="us-ascii"
890 Content-Type: text/plain; charset="us-ascii"
874 MIME-Version: 1.0
891 MIME-Version: 1.0
875 Content-Transfer-Encoding: 7bit
892 Content-Transfer-Encoding: 7bit
876
893
877 Patch subject is complete summary.
894 Patch subject is complete summary.
878
895
879
896
880
897
881 --===
898 --===
882 Content-Type: text/x-patch; charset="us-ascii"
899 Content-Type: text/x-patch; charset="us-ascii"
883 MIME-Version: 1.0
900 MIME-Version: 1.0
884 Content-Transfer-Encoding: 7bit
901 Content-Transfer-Encoding: 7bit
885 Content-Disposition: attachment; filename=t2-1.patch
902 Content-Disposition: attachment; filename=t2-1.patch
886
903
887 # HG changeset patch
904 # HG changeset patch
888 # User test
905 # User test
889 # Date 1 0
906 # Date 1 0
890 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
907 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
891 # Parent 0000000000000000000000000000000000000000
908 # Parent 0000000000000000000000000000000000000000
892 a
909 a
893
910
894 diff -r 000000000000 -r 8580ff50825a a
911 diff -r 000000000000 -r 8580ff50825a a
895 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
912 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
896 +++ b/a Thu Jan 01 00:00:01 1970 +0000
913 +++ b/a Thu Jan 01 00:00:01 1970 +0000
897 @@ -0,0 +1,1 @@
914 @@ -0,0 +1,1 @@
898 +a
915 +a
899
916
900 --===
917 --===
901 Displaying [PATCH 2 of 3] b ...
918 Displaying [PATCH 2 of 3] b ...
902 Content-Type: multipart/mixed; boundary="===
919 Content-Type: multipart/mixed; boundary="===
903 MIME-Version: 1.0
920 MIME-Version: 1.0
904 Subject: [PATCH 2 of 3] b
921 Subject: [PATCH 2 of 3] b
905 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
922 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
906 Message-Id: <97d72e5f12c7e84f8506.62@
923 Message-Id: <97d72e5f12c7e84f8506.62@
907 In-Reply-To: <patchbomb.60@
924 In-Reply-To: <patchbomb.60@
908 References: <patchbomb.60@
925 References: <patchbomb.60@
909 User-Agent: Mercurial-patchbomb
926 User-Agent: Mercurial-patchbomb
910 Date: Thu, 01 Jan 1970 00:01:02 +0000
927 Date: Thu, 01 Jan 1970 00:01:02 +0000
911 From: quux
928 From: quux
912 To: foo
929 To: foo
913 Cc: bar
930 Cc: bar
914
931
915 --===
932 --===
916 Content-Type: text/plain; charset="us-ascii"
933 Content-Type: text/plain; charset="us-ascii"
917 MIME-Version: 1.0
934 MIME-Version: 1.0
918 Content-Transfer-Encoding: 7bit
935 Content-Transfer-Encoding: 7bit
919
936
920 Patch subject is complete summary.
937 Patch subject is complete summary.
921
938
922
939
923
940
924 --===
941 --===
925 Content-Type: text/x-patch; charset="us-ascii"
942 Content-Type: text/x-patch; charset="us-ascii"
926 MIME-Version: 1.0
943 MIME-Version: 1.0
927 Content-Transfer-Encoding: 7bit
944 Content-Transfer-Encoding: 7bit
928 Content-Disposition: attachment; filename=t2-2.patch
945 Content-Disposition: attachment; filename=t2-2.patch
929
946
930 # HG changeset patch
947 # HG changeset patch
931 # User test
948 # User test
932 # Date 2 0
949 # Date 2 0
933 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
950 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
934 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
951 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
935 b
952 b
936
953
937 diff -r 8580ff50825a -r 97d72e5f12c7 b
954 diff -r 8580ff50825a -r 97d72e5f12c7 b
938 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
955 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
939 +++ b/b Thu Jan 01 00:00:02 1970 +0000
956 +++ b/b Thu Jan 01 00:00:02 1970 +0000
940 @@ -0,0 +1,1 @@
957 @@ -0,0 +1,1 @@
941 +b
958 +b
942
959
943 --===
960 --===
944 Displaying [PATCH 3 of 3] charset=utf-8; content-transfer-encoding: quoted-printable ...
961 Displaying [PATCH 3 of 3] charset=utf-8; content-transfer-encoding: quoted-printable ...
945 Content-Type: multipart/mixed; boundary="===
962 Content-Type: multipart/mixed; boundary="===
946 MIME-Version: 1.0
963 MIME-Version: 1.0
947 Subject: [PATCH 3 of 3] charset=utf-8;
964 Subject: [PATCH 3 of 3] charset=utf-8;
948 content-transfer-encoding: quoted-printable
965 content-transfer-encoding: quoted-printable
949 X-Mercurial-Node: c655633f8c87700bb38cc6a59a2753bdc5a6c376
966 X-Mercurial-Node: c655633f8c87700bb38cc6a59a2753bdc5a6c376
950 Message-Id: <c655633f8c87700bb38c.63@
967 Message-Id: <c655633f8c87700bb38c.63@
951 In-Reply-To: <patchbomb.60@
968 In-Reply-To: <patchbomb.60@
952 References: <patchbomb.60@
969 References: <patchbomb.60@
953 User-Agent: Mercurial-patchbomb
970 User-Agent: Mercurial-patchbomb
954 Date: Thu, 01 Jan 1970 00:01:03 +0000
971 Date: Thu, 01 Jan 1970 00:01:03 +0000
955 From: quux
972 From: quux
956 To: foo
973 To: foo
957 Cc: bar
974 Cc: bar
958
975
959 --===
976 --===
960 Content-Type: text/plain; charset="us-ascii"
977 Content-Type: text/plain; charset="us-ascii"
961 MIME-Version: 1.0
978 MIME-Version: 1.0
962 Content-Transfer-Encoding: 7bit
979 Content-Transfer-Encoding: 7bit
963
980
964 Patch subject is complete summary.
981 Patch subject is complete summary.
965
982
966
983
967
984
968 --===
985 --===
969 Content-Type: text/x-patch; charset="us-ascii"
986 Content-Type: text/x-patch; charset="us-ascii"
970 MIME-Version: 1.0
987 MIME-Version: 1.0
971 Content-Transfer-Encoding: quoted-printable
988 Content-Transfer-Encoding: quoted-printable
972 Content-Disposition: attachment; filename=t2-3.patch
989 Content-Disposition: attachment; filename=t2-3.patch
973
990
974 # HG changeset patch
991 # HG changeset patch
975 # User test
992 # User test
976 # Date 4 0
993 # Date 4 0
977 # Node ID c655633f8c87700bb38cc6a59a2753bdc5a6c376
994 # Node ID c655633f8c87700bb38cc6a59a2753bdc5a6c376
978 # Parent c3c9e37db9f4fe4882cda39baf42fed6bad8b15a
995 # Parent c3c9e37db9f4fe4882cda39baf42fed6bad8b15a
979 charset=3Dutf-8; content-transfer-encoding: quoted-printable
996 charset=3Dutf-8; content-transfer-encoding: quoted-printable
980
997
981 diff -r c3c9e37db9f4 -r c655633f8c87 qp
998 diff -r c3c9e37db9f4 -r c655633f8c87 qp
982 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
999 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
983 +++ b/qp Thu Jan 01 00:00:04 1970 +0000
1000 +++ b/qp Thu Jan 01 00:00:04 1970 +0000
984 @@ -0,0 +1,4 @@
1001 @@ -0,0 +1,4 @@
985 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1002 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
986 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1003 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
987 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1004 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
988 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1005 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
989 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1006 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
990 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1007 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
991 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1008 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
992 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1009 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
993 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1010 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
994 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1011 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
995 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1012 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
996 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1013 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
997 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1014 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
998 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
1015 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
999 +foo
1016 +foo
1000 +
1017 +
1001 +bar
1018 +bar
1002
1019
1003 --===
1020 --===
1004
1021
1005 test intro for single patch:
1022 test intro for single patch:
1006 $ hg email --date '1970-1-1 0:1' -n --intro -f quux -t foo -c bar -s test \
1023 $ hg email --date '1970-1-1 0:1' -n --intro -f quux -t foo -c bar -s test \
1007 > -r 2 | fixheaders
1024 > -r 2 | fixheaders
1008 This patch series consists of 1 patches.
1025 This patch series consists of 1 patches.
1009
1026
1010
1027
1011 Write the introductory message for the patch series.
1028 Write the introductory message for the patch series.
1012
1029
1013
1030
1014 Displaying [PATCH 0 of 1] test ...
1031 Displaying [PATCH 0 of 1] test ...
1015 Content-Type: text/plain; charset="us-ascii"
1032 Content-Type: text/plain; charset="us-ascii"
1016 MIME-Version: 1.0
1033 MIME-Version: 1.0
1017 Content-Transfer-Encoding: 7bit
1034 Content-Transfer-Encoding: 7bit
1018 Subject: [PATCH 0 of 1] test
1035 Subject: [PATCH 0 of 1] test
1019 Message-Id: <patchbomb.60@
1036 Message-Id: <patchbomb.60@
1020 User-Agent: Mercurial-patchbomb
1037 User-Agent: Mercurial-patchbomb
1021 Date: Thu, 01 Jan 1970 00:01:00 +0000
1038 Date: Thu, 01 Jan 1970 00:01:00 +0000
1022 From: quux
1039 From: quux
1023 To: foo
1040 To: foo
1024 Cc: bar
1041 Cc: bar
1025
1042
1026
1043
1027 Displaying [PATCH 1 of 1] c ...
1044 Displaying [PATCH 1 of 1] c ...
1028 Content-Type: text/plain; charset="us-ascii"
1045 Content-Type: text/plain; charset="us-ascii"
1029 MIME-Version: 1.0
1046 MIME-Version: 1.0
1030 Content-Transfer-Encoding: 7bit
1047 Content-Transfer-Encoding: 7bit
1031 Subject: [PATCH 1 of 1] c
1048 Subject: [PATCH 1 of 1] c
1032 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1049 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1033 Message-Id: <ff2c9fa2018b15fa74b3.61@
1050 Message-Id: <ff2c9fa2018b15fa74b3.61@
1034 In-Reply-To: <patchbomb.60@
1051 In-Reply-To: <patchbomb.60@
1035 References: <patchbomb.60@
1052 References: <patchbomb.60@
1036 User-Agent: Mercurial-patchbomb
1053 User-Agent: Mercurial-patchbomb
1037 Date: Thu, 01 Jan 1970 00:01:01 +0000
1054 Date: Thu, 01 Jan 1970 00:01:01 +0000
1038 From: quux
1055 From: quux
1039 To: foo
1056 To: foo
1040 Cc: bar
1057 Cc: bar
1041
1058
1042 # HG changeset patch
1059 # HG changeset patch
1043 # User test
1060 # User test
1044 # Date 3 0
1061 # Date 3 0
1045 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1062 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1046 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1063 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1047 c
1064 c
1048
1065
1049 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1066 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1050 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1067 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1051 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1068 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1052 @@ -0,0 +1,1 @@
1069 @@ -0,0 +1,1 @@
1053 +c
1070 +c
1054
1071
1055
1072
1056 test --desc without --intro for a single patch:
1073 test --desc without --intro for a single patch:
1057 $ echo foo > intro.text
1074 $ echo foo > intro.text
1058 $ hg email --date '1970-1-1 0:1' -n --desc intro.text -f quux -t foo -c bar \
1075 $ hg email --date '1970-1-1 0:1' -n --desc intro.text -f quux -t foo -c bar \
1059 > -s test -r 2 | fixheaders
1076 > -s test -r 2 | fixheaders
1060 This patch series consists of 1 patches.
1077 This patch series consists of 1 patches.
1061
1078
1062
1079
1063 Displaying [PATCH 0 of 1] test ...
1080 Displaying [PATCH 0 of 1] test ...
1064 Content-Type: text/plain; charset="us-ascii"
1081 Content-Type: text/plain; charset="us-ascii"
1065 MIME-Version: 1.0
1082 MIME-Version: 1.0
1066 Content-Transfer-Encoding: 7bit
1083 Content-Transfer-Encoding: 7bit
1067 Subject: [PATCH 0 of 1] test
1084 Subject: [PATCH 0 of 1] test
1068 Message-Id: <patchbomb.60@
1085 Message-Id: <patchbomb.60@
1069 User-Agent: Mercurial-patchbomb
1086 User-Agent: Mercurial-patchbomb
1070 Date: Thu, 01 Jan 1970 00:01:00 +0000
1087 Date: Thu, 01 Jan 1970 00:01:00 +0000
1071 From: quux
1088 From: quux
1072 To: foo
1089 To: foo
1073 Cc: bar
1090 Cc: bar
1074
1091
1075 foo
1092 foo
1076
1093
1077 Displaying [PATCH 1 of 1] c ...
1094 Displaying [PATCH 1 of 1] c ...
1078 Content-Type: text/plain; charset="us-ascii"
1095 Content-Type: text/plain; charset="us-ascii"
1079 MIME-Version: 1.0
1096 MIME-Version: 1.0
1080 Content-Transfer-Encoding: 7bit
1097 Content-Transfer-Encoding: 7bit
1081 Subject: [PATCH 1 of 1] c
1098 Subject: [PATCH 1 of 1] c
1082 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1099 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1083 Message-Id: <ff2c9fa2018b15fa74b3.61@
1100 Message-Id: <ff2c9fa2018b15fa74b3.61@
1084 In-Reply-To: <patchbomb.60@
1101 In-Reply-To: <patchbomb.60@
1085 References: <patchbomb.60@
1102 References: <patchbomb.60@
1086 User-Agent: Mercurial-patchbomb
1103 User-Agent: Mercurial-patchbomb
1087 Date: Thu, 01 Jan 1970 00:01:01 +0000
1104 Date: Thu, 01 Jan 1970 00:01:01 +0000
1088 From: quux
1105 From: quux
1089 To: foo
1106 To: foo
1090 Cc: bar
1107 Cc: bar
1091
1108
1092 # HG changeset patch
1109 # HG changeset patch
1093 # User test
1110 # User test
1094 # Date 3 0
1111 # Date 3 0
1095 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1112 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1096 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1113 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1097 c
1114 c
1098
1115
1099 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1116 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1100 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1117 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1101 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1118 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1102 @@ -0,0 +1,1 @@
1119 @@ -0,0 +1,1 @@
1103 +c
1120 +c
1104
1121
1105
1122
1106 test intro for multiple patches:
1123 test intro for multiple patches:
1107 $ hg email --date '1970-1-1 0:1' -n --intro -f quux -t foo -c bar -s test \
1124 $ hg email --date '1970-1-1 0:1' -n --intro -f quux -t foo -c bar -s test \
1108 > -r 0:1 | fixheaders
1125 > -r 0:1 | fixheaders
1109 This patch series consists of 2 patches.
1126 This patch series consists of 2 patches.
1110
1127
1111
1128
1112 Write the introductory message for the patch series.
1129 Write the introductory message for the patch series.
1113
1130
1114
1131
1115 Displaying [PATCH 0 of 2] test ...
1132 Displaying [PATCH 0 of 2] test ...
1116 Content-Type: text/plain; charset="us-ascii"
1133 Content-Type: text/plain; charset="us-ascii"
1117 MIME-Version: 1.0
1134 MIME-Version: 1.0
1118 Content-Transfer-Encoding: 7bit
1135 Content-Transfer-Encoding: 7bit
1119 Subject: [PATCH 0 of 2] test
1136 Subject: [PATCH 0 of 2] test
1120 Message-Id: <patchbomb.60@
1137 Message-Id: <patchbomb.60@
1121 User-Agent: Mercurial-patchbomb
1138 User-Agent: Mercurial-patchbomb
1122 Date: Thu, 01 Jan 1970 00:01:00 +0000
1139 Date: Thu, 01 Jan 1970 00:01:00 +0000
1123 From: quux
1140 From: quux
1124 To: foo
1141 To: foo
1125 Cc: bar
1142 Cc: bar
1126
1143
1127
1144
1128 Displaying [PATCH 1 of 2] a ...
1145 Displaying [PATCH 1 of 2] a ...
1129 Content-Type: text/plain; charset="us-ascii"
1146 Content-Type: text/plain; charset="us-ascii"
1130 MIME-Version: 1.0
1147 MIME-Version: 1.0
1131 Content-Transfer-Encoding: 7bit
1148 Content-Transfer-Encoding: 7bit
1132 Subject: [PATCH 1 of 2] a
1149 Subject: [PATCH 1 of 2] a
1133 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
1150 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
1134 Message-Id: <8580ff50825a50c8f716.61@
1151 Message-Id: <8580ff50825a50c8f716.61@
1135 In-Reply-To: <patchbomb.60@
1152 In-Reply-To: <patchbomb.60@
1136 References: <patchbomb.60@
1153 References: <patchbomb.60@
1137 User-Agent: Mercurial-patchbomb
1154 User-Agent: Mercurial-patchbomb
1138 Date: Thu, 01 Jan 1970 00:01:01 +0000
1155 Date: Thu, 01 Jan 1970 00:01:01 +0000
1139 From: quux
1156 From: quux
1140 To: foo
1157 To: foo
1141 Cc: bar
1158 Cc: bar
1142
1159
1143 # HG changeset patch
1160 # HG changeset patch
1144 # User test
1161 # User test
1145 # Date 1 0
1162 # Date 1 0
1146 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
1163 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
1147 # Parent 0000000000000000000000000000000000000000
1164 # Parent 0000000000000000000000000000000000000000
1148 a
1165 a
1149
1166
1150 diff -r 000000000000 -r 8580ff50825a a
1167 diff -r 000000000000 -r 8580ff50825a a
1151 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1168 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1152 +++ b/a Thu Jan 01 00:00:01 1970 +0000
1169 +++ b/a Thu Jan 01 00:00:01 1970 +0000
1153 @@ -0,0 +1,1 @@
1170 @@ -0,0 +1,1 @@
1154 +a
1171 +a
1155
1172
1156 Displaying [PATCH 2 of 2] b ...
1173 Displaying [PATCH 2 of 2] b ...
1157 Content-Type: text/plain; charset="us-ascii"
1174 Content-Type: text/plain; charset="us-ascii"
1158 MIME-Version: 1.0
1175 MIME-Version: 1.0
1159 Content-Transfer-Encoding: 7bit
1176 Content-Transfer-Encoding: 7bit
1160 Subject: [PATCH 2 of 2] b
1177 Subject: [PATCH 2 of 2] b
1161 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1178 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1162 Message-Id: <97d72e5f12c7e84f8506.62@
1179 Message-Id: <97d72e5f12c7e84f8506.62@
1163 In-Reply-To: <patchbomb.60@
1180 In-Reply-To: <patchbomb.60@
1164 References: <patchbomb.60@
1181 References: <patchbomb.60@
1165 User-Agent: Mercurial-patchbomb
1182 User-Agent: Mercurial-patchbomb
1166 Date: Thu, 01 Jan 1970 00:01:02 +0000
1183 Date: Thu, 01 Jan 1970 00:01:02 +0000
1167 From: quux
1184 From: quux
1168 To: foo
1185 To: foo
1169 Cc: bar
1186 Cc: bar
1170
1187
1171 # HG changeset patch
1188 # HG changeset patch
1172 # User test
1189 # User test
1173 # Date 2 0
1190 # Date 2 0
1174 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1191 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1175 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
1192 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
1176 b
1193 b
1177
1194
1178 diff -r 8580ff50825a -r 97d72e5f12c7 b
1195 diff -r 8580ff50825a -r 97d72e5f12c7 b
1179 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1196 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1180 +++ b/b Thu Jan 01 00:00:02 1970 +0000
1197 +++ b/b Thu Jan 01 00:00:02 1970 +0000
1181 @@ -0,0 +1,1 @@
1198 @@ -0,0 +1,1 @@
1182 +b
1199 +b
1183
1200
1184
1201
1185 test reply-to via config:
1202 test reply-to via config:
1186 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -r 2 \
1203 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -r 2 \
1187 > --config patchbomb.reply-to='baz@example.com' | fixheaders
1204 > --config patchbomb.reply-to='baz@example.com' | fixheaders
1188 This patch series consists of 1 patches.
1205 This patch series consists of 1 patches.
1189
1206
1190
1207
1191 Displaying [PATCH] test ...
1208 Displaying [PATCH] test ...
1192 Content-Type: text/plain; charset="us-ascii"
1209 Content-Type: text/plain; charset="us-ascii"
1193 MIME-Version: 1.0
1210 MIME-Version: 1.0
1194 Content-Transfer-Encoding: 7bit
1211 Content-Transfer-Encoding: 7bit
1195 Subject: [PATCH] test
1212 Subject: [PATCH] test
1196 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1213 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1197 Message-Id: <ff2c9fa2018b15fa74b3.60@
1214 Message-Id: <ff2c9fa2018b15fa74b3.60@
1198 User-Agent: Mercurial-patchbomb
1215 User-Agent: Mercurial-patchbomb
1199 Date: Thu, 01 Jan 1970 00:01:00 +0000
1216 Date: Thu, 01 Jan 1970 00:01:00 +0000
1200 From: quux
1217 From: quux
1201 To: foo
1218 To: foo
1202 Cc: bar
1219 Cc: bar
1203 Reply-To: baz@example.com
1220 Reply-To: baz@example.com
1204
1221
1205 # HG changeset patch
1222 # HG changeset patch
1206 # User test
1223 # User test
1207 # Date 3 0
1224 # Date 3 0
1208 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1225 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1209 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1226 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1210 c
1227 c
1211
1228
1212 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1229 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1213 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1230 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1214 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1231 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1215 @@ -0,0 +1,1 @@
1232 @@ -0,0 +1,1 @@
1216 +c
1233 +c
1217
1234
1218
1235
1219 test reply-to via command line:
1236 test reply-to via command line:
1220 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -r 2 \
1237 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -r 2 \
1221 > --reply-to baz --reply-to fred | fixheaders
1238 > --reply-to baz --reply-to fred | fixheaders
1222 This patch series consists of 1 patches.
1239 This patch series consists of 1 patches.
1223
1240
1224
1241
1225 Displaying [PATCH] test ...
1242 Displaying [PATCH] test ...
1226 Content-Type: text/plain; charset="us-ascii"
1243 Content-Type: text/plain; charset="us-ascii"
1227 MIME-Version: 1.0
1244 MIME-Version: 1.0
1228 Content-Transfer-Encoding: 7bit
1245 Content-Transfer-Encoding: 7bit
1229 Subject: [PATCH] test
1246 Subject: [PATCH] test
1230 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1247 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1231 Message-Id: <ff2c9fa2018b15fa74b3.60@
1248 Message-Id: <ff2c9fa2018b15fa74b3.60@
1232 User-Agent: Mercurial-patchbomb
1249 User-Agent: Mercurial-patchbomb
1233 Date: Thu, 01 Jan 1970 00:01:00 +0000
1250 Date: Thu, 01 Jan 1970 00:01:00 +0000
1234 From: quux
1251 From: quux
1235 To: foo
1252 To: foo
1236 Cc: bar
1253 Cc: bar
1237 Reply-To: baz, fred
1254 Reply-To: baz, fred
1238
1255
1239 # HG changeset patch
1256 # HG changeset patch
1240 # User test
1257 # User test
1241 # Date 3 0
1258 # Date 3 0
1242 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1259 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1243 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1260 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1244 c
1261 c
1245
1262
1246 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1263 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1247 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1264 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1248 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1265 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1249 @@ -0,0 +1,1 @@
1266 @@ -0,0 +1,1 @@
1250 +c
1267 +c
1251
1268
1252
1269
1253 tagging csets:
1270 tagging csets:
1254 $ hg tag -r0 zero zero.foo
1271 $ hg tag -r0 zero zero.foo
1255 $ hg tag -r1 one one.patch
1272 $ hg tag -r1 one one.patch
1256 $ hg tag -r2 two two.diff
1273 $ hg tag -r2 two two.diff
1257
1274
1258 test inline for single named patch:
1275 test inline for single named patch:
1259 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -i -r 2 | \
1276 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -i -r 2 | \
1260 > fixheaders
1277 > fixheaders
1261 This patch series consists of 1 patches.
1278 This patch series consists of 1 patches.
1262
1279
1263
1280
1264 Displaying [PATCH] test ...
1281 Displaying [PATCH] test ...
1265 Content-Type: multipart/mixed; boundary="===
1282 Content-Type: multipart/mixed; boundary="===
1266 MIME-Version: 1.0
1283 MIME-Version: 1.0
1267 Subject: [PATCH] test
1284 Subject: [PATCH] test
1268 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1285 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1269 Message-Id: <ff2c9fa2018b15fa74b3.60@
1286 Message-Id: <ff2c9fa2018b15fa74b3.60@
1270 User-Agent: Mercurial-patchbomb
1287 User-Agent: Mercurial-patchbomb
1271 Date: Thu, 01 Jan 1970 00:01:00 +0000
1288 Date: Thu, 01 Jan 1970 00:01:00 +0000
1272 From: quux
1289 From: quux
1273 To: foo
1290 To: foo
1274 Cc: bar
1291 Cc: bar
1275
1292
1276 --===
1293 --===
1277 Content-Type: text/x-patch; charset="us-ascii"
1294 Content-Type: text/x-patch; charset="us-ascii"
1278 MIME-Version: 1.0
1295 MIME-Version: 1.0
1279 Content-Transfer-Encoding: 7bit
1296 Content-Transfer-Encoding: 7bit
1280 Content-Disposition: inline; filename=two.diff
1297 Content-Disposition: inline; filename=two.diff
1281
1298
1282 # HG changeset patch
1299 # HG changeset patch
1283 # User test
1300 # User test
1284 # Date 3 0
1301 # Date 3 0
1285 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1302 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1286 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1303 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1287 c
1304 c
1288
1305
1289 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1306 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1290 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1307 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1291 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1308 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1292 @@ -0,0 +1,1 @@
1309 @@ -0,0 +1,1 @@
1293 +c
1310 +c
1294
1311
1295 --===
1312 --===
1296
1313
1297 test inline for multiple named/unnamed patches:
1314 test inline for multiple named/unnamed patches:
1298 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -i -r 0:1 | \
1315 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar -s test -i -r 0:1 | \
1299 > fixheaders
1316 > fixheaders
1300 This patch series consists of 2 patches.
1317 This patch series consists of 2 patches.
1301
1318
1302
1319
1303 Write the introductory message for the patch series.
1320 Write the introductory message for the patch series.
1304
1321
1305
1322
1306 Displaying [PATCH 0 of 2] test ...
1323 Displaying [PATCH 0 of 2] test ...
1307 Content-Type: text/plain; charset="us-ascii"
1324 Content-Type: text/plain; charset="us-ascii"
1308 MIME-Version: 1.0
1325 MIME-Version: 1.0
1309 Content-Transfer-Encoding: 7bit
1326 Content-Transfer-Encoding: 7bit
1310 Subject: [PATCH 0 of 2] test
1327 Subject: [PATCH 0 of 2] test
1311 Message-Id: <patchbomb.60@
1328 Message-Id: <patchbomb.60@
1312 User-Agent: Mercurial-patchbomb
1329 User-Agent: Mercurial-patchbomb
1313 Date: Thu, 01 Jan 1970 00:01:00 +0000
1330 Date: Thu, 01 Jan 1970 00:01:00 +0000
1314 From: quux
1331 From: quux
1315 To: foo
1332 To: foo
1316 Cc: bar
1333 Cc: bar
1317
1334
1318
1335
1319 Displaying [PATCH 1 of 2] a ...
1336 Displaying [PATCH 1 of 2] a ...
1320 Content-Type: multipart/mixed; boundary="===
1337 Content-Type: multipart/mixed; boundary="===
1321 MIME-Version: 1.0
1338 MIME-Version: 1.0
1322 Subject: [PATCH 1 of 2] a
1339 Subject: [PATCH 1 of 2] a
1323 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
1340 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
1324 Message-Id: <8580ff50825a50c8f716.61@
1341 Message-Id: <8580ff50825a50c8f716.61@
1325 In-Reply-To: <patchbomb.60@
1342 In-Reply-To: <patchbomb.60@
1326 References: <patchbomb.60@
1343 References: <patchbomb.60@
1327 User-Agent: Mercurial-patchbomb
1344 User-Agent: Mercurial-patchbomb
1328 Date: Thu, 01 Jan 1970 00:01:01 +0000
1345 Date: Thu, 01 Jan 1970 00:01:01 +0000
1329 From: quux
1346 From: quux
1330 To: foo
1347 To: foo
1331 Cc: bar
1348 Cc: bar
1332
1349
1333 --===
1350 --===
1334 Content-Type: text/x-patch; charset="us-ascii"
1351 Content-Type: text/x-patch; charset="us-ascii"
1335 MIME-Version: 1.0
1352 MIME-Version: 1.0
1336 Content-Transfer-Encoding: 7bit
1353 Content-Transfer-Encoding: 7bit
1337 Content-Disposition: inline; filename=t2-1.patch
1354 Content-Disposition: inline; filename=t2-1.patch
1338
1355
1339 # HG changeset patch
1356 # HG changeset patch
1340 # User test
1357 # User test
1341 # Date 1 0
1358 # Date 1 0
1342 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
1359 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
1343 # Parent 0000000000000000000000000000000000000000
1360 # Parent 0000000000000000000000000000000000000000
1344 a
1361 a
1345
1362
1346 diff -r 000000000000 -r 8580ff50825a a
1363 diff -r 000000000000 -r 8580ff50825a a
1347 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1364 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1348 +++ b/a Thu Jan 01 00:00:01 1970 +0000
1365 +++ b/a Thu Jan 01 00:00:01 1970 +0000
1349 @@ -0,0 +1,1 @@
1366 @@ -0,0 +1,1 @@
1350 +a
1367 +a
1351
1368
1352 --===
1369 --===
1353 Displaying [PATCH 2 of 2] b ...
1370 Displaying [PATCH 2 of 2] b ...
1354 Content-Type: multipart/mixed; boundary="===
1371 Content-Type: multipart/mixed; boundary="===
1355 MIME-Version: 1.0
1372 MIME-Version: 1.0
1356 Subject: [PATCH 2 of 2] b
1373 Subject: [PATCH 2 of 2] b
1357 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1374 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1358 Message-Id: <97d72e5f12c7e84f8506.62@
1375 Message-Id: <97d72e5f12c7e84f8506.62@
1359 In-Reply-To: <patchbomb.60@
1376 In-Reply-To: <patchbomb.60@
1360 References: <patchbomb.60@
1377 References: <patchbomb.60@
1361 User-Agent: Mercurial-patchbomb
1378 User-Agent: Mercurial-patchbomb
1362 Date: Thu, 01 Jan 1970 00:01:02 +0000
1379 Date: Thu, 01 Jan 1970 00:01:02 +0000
1363 From: quux
1380 From: quux
1364 To: foo
1381 To: foo
1365 Cc: bar
1382 Cc: bar
1366
1383
1367 --===
1384 --===
1368 Content-Type: text/x-patch; charset="us-ascii"
1385 Content-Type: text/x-patch; charset="us-ascii"
1369 MIME-Version: 1.0
1386 MIME-Version: 1.0
1370 Content-Transfer-Encoding: 7bit
1387 Content-Transfer-Encoding: 7bit
1371 Content-Disposition: inline; filename=one.patch
1388 Content-Disposition: inline; filename=one.patch
1372
1389
1373 # HG changeset patch
1390 # HG changeset patch
1374 # User test
1391 # User test
1375 # Date 2 0
1392 # Date 2 0
1376 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1393 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1377 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
1394 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
1378 b
1395 b
1379
1396
1380 diff -r 8580ff50825a -r 97d72e5f12c7 b
1397 diff -r 8580ff50825a -r 97d72e5f12c7 b
1381 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1398 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1382 +++ b/b Thu Jan 01 00:00:02 1970 +0000
1399 +++ b/b Thu Jan 01 00:00:02 1970 +0000
1383 @@ -0,0 +1,1 @@
1400 @@ -0,0 +1,1 @@
1384 +b
1401 +b
1385
1402
1386 --===
1403 --===
1387
1404
1388
1405
1389 test inreplyto:
1406 test inreplyto:
1390 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar --in-reply-to baz \
1407 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar --in-reply-to baz \
1391 > -r tip | fixheaders
1408 > -r tip | fixheaders
1392 This patch series consists of 1 patches.
1409 This patch series consists of 1 patches.
1393
1410
1394
1411
1395 Displaying [PATCH] Added tag two, two.diff for changeset ff2c9fa2018b ...
1412 Displaying [PATCH] Added tag two, two.diff for changeset ff2c9fa2018b ...
1396 Content-Type: text/plain; charset="us-ascii"
1413 Content-Type: text/plain; charset="us-ascii"
1397 MIME-Version: 1.0
1414 MIME-Version: 1.0
1398 Content-Transfer-Encoding: 7bit
1415 Content-Transfer-Encoding: 7bit
1399 Subject: [PATCH] Added tag two, two.diff for changeset ff2c9fa2018b
1416 Subject: [PATCH] Added tag two, two.diff for changeset ff2c9fa2018b
1400 X-Mercurial-Node: e317db6a6f288748d1f6cb064f3810fcba66b1b6
1417 X-Mercurial-Node: e317db6a6f288748d1f6cb064f3810fcba66b1b6
1401 Message-Id: <e317db6a6f288748d1f6.60@
1418 Message-Id: <e317db6a6f288748d1f6.60@
1402 In-Reply-To: <baz>
1419 In-Reply-To: <baz>
1403 References: <baz>
1420 References: <baz>
1404 User-Agent: Mercurial-patchbomb
1421 User-Agent: Mercurial-patchbomb
1405 Date: Thu, 01 Jan 1970 00:01:00 +0000
1422 Date: Thu, 01 Jan 1970 00:01:00 +0000
1406 From: quux
1423 From: quux
1407 To: foo
1424 To: foo
1408 Cc: bar
1425 Cc: bar
1409
1426
1410 # HG changeset patch
1427 # HG changeset patch
1411 # User test
1428 # User test
1412 # Date 0 0
1429 # Date 0 0
1413 # Node ID e317db6a6f288748d1f6cb064f3810fcba66b1b6
1430 # Node ID e317db6a6f288748d1f6cb064f3810fcba66b1b6
1414 # Parent eae5fcf795eee29d0e45ffc9f519a91cd79fc9ff
1431 # Parent eae5fcf795eee29d0e45ffc9f519a91cd79fc9ff
1415 Added tag two, two.diff for changeset ff2c9fa2018b
1432 Added tag two, two.diff for changeset ff2c9fa2018b
1416
1433
1417 diff -r eae5fcf795ee -r e317db6a6f28 .hgtags
1434 diff -r eae5fcf795ee -r e317db6a6f28 .hgtags
1418 --- a/.hgtags Thu Jan 01 00:00:00 1970 +0000
1435 --- a/.hgtags Thu Jan 01 00:00:00 1970 +0000
1419 +++ b/.hgtags Thu Jan 01 00:00:00 1970 +0000
1436 +++ b/.hgtags Thu Jan 01 00:00:00 1970 +0000
1420 @@ -2,3 +2,5 @@
1437 @@ -2,3 +2,5 @@
1421 8580ff50825a50c8f716709acdf8de0deddcd6ab zero.foo
1438 8580ff50825a50c8f716709acdf8de0deddcd6ab zero.foo
1422 97d72e5f12c7e84f85064aa72e5a297142c36ed9 one
1439 97d72e5f12c7e84f85064aa72e5a297142c36ed9 one
1423 97d72e5f12c7e84f85064aa72e5a297142c36ed9 one.patch
1440 97d72e5f12c7e84f85064aa72e5a297142c36ed9 one.patch
1424 +ff2c9fa2018b15fa74b33363bda9527323e2a99f two
1441 +ff2c9fa2018b15fa74b33363bda9527323e2a99f two
1425 +ff2c9fa2018b15fa74b33363bda9527323e2a99f two.diff
1442 +ff2c9fa2018b15fa74b33363bda9527323e2a99f two.diff
1426
1443
1427
1444
1428 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar --in-reply-to baz \
1445 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar --in-reply-to baz \
1429 > -r 0:1
1446 > -r 0:1
1430 This patch series consists of 2 patches.
1447 This patch series consists of 2 patches.
1431
1448
1432 abort: Subject: [PATCH 0 of 2] Please enter a valid value
1449 abort: Subject: [PATCH 0 of 2] Please enter a valid value
1433
1450
1434 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar --in-reply-to baz \
1451 $ hg email --date '1970-1-1 0:1' -n -f quux -t foo -c bar --in-reply-to baz \
1435 > -s test -r 0:1 | fixheaders
1452 > -s test -r 0:1 | fixheaders
1436 This patch series consists of 2 patches.
1453 This patch series consists of 2 patches.
1437
1454
1438
1455
1439 Write the introductory message for the patch series.
1456 Write the introductory message for the patch series.
1440
1457
1441
1458
1442 Displaying [PATCH 0 of 2] test ...
1459 Displaying [PATCH 0 of 2] test ...
1443 Content-Type: text/plain; charset="us-ascii"
1460 Content-Type: text/plain; charset="us-ascii"
1444 MIME-Version: 1.0
1461 MIME-Version: 1.0
1445 Content-Transfer-Encoding: 7bit
1462 Content-Transfer-Encoding: 7bit
1446 Subject: [PATCH 0 of 2] test
1463 Subject: [PATCH 0 of 2] test
1447 Message-Id: <patchbomb.60@
1464 Message-Id: <patchbomb.60@
1448 In-Reply-To: <baz>
1465 In-Reply-To: <baz>
1449 References: <baz>
1466 References: <baz>
1450 User-Agent: Mercurial-patchbomb
1467 User-Agent: Mercurial-patchbomb
1451 Date: Thu, 01 Jan 1970 00:01:00 +0000
1468 Date: Thu, 01 Jan 1970 00:01:00 +0000
1452 From: quux
1469 From: quux
1453 To: foo
1470 To: foo
1454 Cc: bar
1471 Cc: bar
1455
1472
1456
1473
1457 Displaying [PATCH 1 of 2] a ...
1474 Displaying [PATCH 1 of 2] a ...
1458 Content-Type: text/plain; charset="us-ascii"
1475 Content-Type: text/plain; charset="us-ascii"
1459 MIME-Version: 1.0
1476 MIME-Version: 1.0
1460 Content-Transfer-Encoding: 7bit
1477 Content-Transfer-Encoding: 7bit
1461 Subject: [PATCH 1 of 2] a
1478 Subject: [PATCH 1 of 2] a
1462 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
1479 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
1463 Message-Id: <8580ff50825a50c8f716.61@
1480 Message-Id: <8580ff50825a50c8f716.61@
1464 In-Reply-To: <patchbomb.60@
1481 In-Reply-To: <patchbomb.60@
1465 References: <patchbomb.60@
1482 References: <patchbomb.60@
1466 User-Agent: Mercurial-patchbomb
1483 User-Agent: Mercurial-patchbomb
1467 Date: Thu, 01 Jan 1970 00:01:01 +0000
1484 Date: Thu, 01 Jan 1970 00:01:01 +0000
1468 From: quux
1485 From: quux
1469 To: foo
1486 To: foo
1470 Cc: bar
1487 Cc: bar
1471
1488
1472 # HG changeset patch
1489 # HG changeset patch
1473 # User test
1490 # User test
1474 # Date 1 0
1491 # Date 1 0
1475 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
1492 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
1476 # Parent 0000000000000000000000000000000000000000
1493 # Parent 0000000000000000000000000000000000000000
1477 a
1494 a
1478
1495
1479 diff -r 000000000000 -r 8580ff50825a a
1496 diff -r 000000000000 -r 8580ff50825a a
1480 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1497 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1481 +++ b/a Thu Jan 01 00:00:01 1970 +0000
1498 +++ b/a Thu Jan 01 00:00:01 1970 +0000
1482 @@ -0,0 +1,1 @@
1499 @@ -0,0 +1,1 @@
1483 +a
1500 +a
1484
1501
1485 Displaying [PATCH 2 of 2] b ...
1502 Displaying [PATCH 2 of 2] b ...
1486 Content-Type: text/plain; charset="us-ascii"
1503 Content-Type: text/plain; charset="us-ascii"
1487 MIME-Version: 1.0
1504 MIME-Version: 1.0
1488 Content-Transfer-Encoding: 7bit
1505 Content-Transfer-Encoding: 7bit
1489 Subject: [PATCH 2 of 2] b
1506 Subject: [PATCH 2 of 2] b
1490 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1507 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1491 Message-Id: <97d72e5f12c7e84f8506.62@
1508 Message-Id: <97d72e5f12c7e84f8506.62@
1492 In-Reply-To: <patchbomb.60@
1509 In-Reply-To: <patchbomb.60@
1493 References: <patchbomb.60@
1510 References: <patchbomb.60@
1494 User-Agent: Mercurial-patchbomb
1511 User-Agent: Mercurial-patchbomb
1495 Date: Thu, 01 Jan 1970 00:01:02 +0000
1512 Date: Thu, 01 Jan 1970 00:01:02 +0000
1496 From: quux
1513 From: quux
1497 To: foo
1514 To: foo
1498 Cc: bar
1515 Cc: bar
1499
1516
1500 # HG changeset patch
1517 # HG changeset patch
1501 # User test
1518 # User test
1502 # Date 2 0
1519 # Date 2 0
1503 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1520 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1504 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
1521 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
1505 b
1522 b
1506
1523
1507 diff -r 8580ff50825a -r 97d72e5f12c7 b
1524 diff -r 8580ff50825a -r 97d72e5f12c7 b
1508 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1525 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1509 +++ b/b Thu Jan 01 00:00:02 1970 +0000
1526 +++ b/b Thu Jan 01 00:00:02 1970 +0000
1510 @@ -0,0 +1,1 @@
1527 @@ -0,0 +1,1 @@
1511 +b
1528 +b
1512
1529
1513
1530
1514 test single flag for single patch:
1531 test single flag for single patch:
1515 $ hg email --date '1970-1-1 0:1' -n --flag fooFlag -f quux -t foo -c bar -s test \
1532 $ hg email --date '1970-1-1 0:1' -n --flag fooFlag -f quux -t foo -c bar -s test \
1516 > -r 2 | fixheaders
1533 > -r 2 | fixheaders
1517 This patch series consists of 1 patches.
1534 This patch series consists of 1 patches.
1518
1535
1519
1536
1520 Displaying [PATCH fooFlag] test ...
1537 Displaying [PATCH fooFlag] test ...
1521 Content-Type: text/plain; charset="us-ascii"
1538 Content-Type: text/plain; charset="us-ascii"
1522 MIME-Version: 1.0
1539 MIME-Version: 1.0
1523 Content-Transfer-Encoding: 7bit
1540 Content-Transfer-Encoding: 7bit
1524 Subject: [PATCH fooFlag] test
1541 Subject: [PATCH fooFlag] test
1525 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1542 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1526 Message-Id: <ff2c9fa2018b15fa74b3.60@
1543 Message-Id: <ff2c9fa2018b15fa74b3.60@
1527 User-Agent: Mercurial-patchbomb
1544 User-Agent: Mercurial-patchbomb
1528 Date: Thu, 01 Jan 1970 00:01:00 +0000
1545 Date: Thu, 01 Jan 1970 00:01:00 +0000
1529 From: quux
1546 From: quux
1530 To: foo
1547 To: foo
1531 Cc: bar
1548 Cc: bar
1532
1549
1533 # HG changeset patch
1550 # HG changeset patch
1534 # User test
1551 # User test
1535 # Date 3 0
1552 # Date 3 0
1536 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1553 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1537 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1554 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1538 c
1555 c
1539
1556
1540 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1557 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1541 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1558 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1542 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1559 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1543 @@ -0,0 +1,1 @@
1560 @@ -0,0 +1,1 @@
1544 +c
1561 +c
1545
1562
1546
1563
1547 test single flag for multiple patches:
1564 test single flag for multiple patches:
1548 $ hg email --date '1970-1-1 0:1' -n --flag fooFlag -f quux -t foo -c bar -s test \
1565 $ hg email --date '1970-1-1 0:1' -n --flag fooFlag -f quux -t foo -c bar -s test \
1549 > -r 0:1 | fixheaders
1566 > -r 0:1 | fixheaders
1550 This patch series consists of 2 patches.
1567 This patch series consists of 2 patches.
1551
1568
1552
1569
1553 Write the introductory message for the patch series.
1570 Write the introductory message for the patch series.
1554
1571
1555
1572
1556 Displaying [PATCH 0 of 2 fooFlag] test ...
1573 Displaying [PATCH 0 of 2 fooFlag] test ...
1557 Content-Type: text/plain; charset="us-ascii"
1574 Content-Type: text/plain; charset="us-ascii"
1558 MIME-Version: 1.0
1575 MIME-Version: 1.0
1559 Content-Transfer-Encoding: 7bit
1576 Content-Transfer-Encoding: 7bit
1560 Subject: [PATCH 0 of 2 fooFlag] test
1577 Subject: [PATCH 0 of 2 fooFlag] test
1561 Message-Id: <patchbomb.60@
1578 Message-Id: <patchbomb.60@
1562 User-Agent: Mercurial-patchbomb
1579 User-Agent: Mercurial-patchbomb
1563 Date: Thu, 01 Jan 1970 00:01:00 +0000
1580 Date: Thu, 01 Jan 1970 00:01:00 +0000
1564 From: quux
1581 From: quux
1565 To: foo
1582 To: foo
1566 Cc: bar
1583 Cc: bar
1567
1584
1568
1585
1569 Displaying [PATCH 1 of 2 fooFlag] a ...
1586 Displaying [PATCH 1 of 2 fooFlag] a ...
1570 Content-Type: text/plain; charset="us-ascii"
1587 Content-Type: text/plain; charset="us-ascii"
1571 MIME-Version: 1.0
1588 MIME-Version: 1.0
1572 Content-Transfer-Encoding: 7bit
1589 Content-Transfer-Encoding: 7bit
1573 Subject: [PATCH 1 of 2 fooFlag] a
1590 Subject: [PATCH 1 of 2 fooFlag] a
1574 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
1591 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
1575 Message-Id: <8580ff50825a50c8f716.61@
1592 Message-Id: <8580ff50825a50c8f716.61@
1576 In-Reply-To: <patchbomb.60@
1593 In-Reply-To: <patchbomb.60@
1577 References: <patchbomb.60@
1594 References: <patchbomb.60@
1578 User-Agent: Mercurial-patchbomb
1595 User-Agent: Mercurial-patchbomb
1579 Date: Thu, 01 Jan 1970 00:01:01 +0000
1596 Date: Thu, 01 Jan 1970 00:01:01 +0000
1580 From: quux
1597 From: quux
1581 To: foo
1598 To: foo
1582 Cc: bar
1599 Cc: bar
1583
1600
1584 # HG changeset patch
1601 # HG changeset patch
1585 # User test
1602 # User test
1586 # Date 1 0
1603 # Date 1 0
1587 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
1604 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
1588 # Parent 0000000000000000000000000000000000000000
1605 # Parent 0000000000000000000000000000000000000000
1589 a
1606 a
1590
1607
1591 diff -r 000000000000 -r 8580ff50825a a
1608 diff -r 000000000000 -r 8580ff50825a a
1592 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1609 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1593 +++ b/a Thu Jan 01 00:00:01 1970 +0000
1610 +++ b/a Thu Jan 01 00:00:01 1970 +0000
1594 @@ -0,0 +1,1 @@
1611 @@ -0,0 +1,1 @@
1595 +a
1612 +a
1596
1613
1597 Displaying [PATCH 2 of 2 fooFlag] b ...
1614 Displaying [PATCH 2 of 2 fooFlag] b ...
1598 Content-Type: text/plain; charset="us-ascii"
1615 Content-Type: text/plain; charset="us-ascii"
1599 MIME-Version: 1.0
1616 MIME-Version: 1.0
1600 Content-Transfer-Encoding: 7bit
1617 Content-Transfer-Encoding: 7bit
1601 Subject: [PATCH 2 of 2 fooFlag] b
1618 Subject: [PATCH 2 of 2 fooFlag] b
1602 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1619 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1603 Message-Id: <97d72e5f12c7e84f8506.62@
1620 Message-Id: <97d72e5f12c7e84f8506.62@
1604 In-Reply-To: <patchbomb.60@
1621 In-Reply-To: <patchbomb.60@
1605 References: <patchbomb.60@
1622 References: <patchbomb.60@
1606 User-Agent: Mercurial-patchbomb
1623 User-Agent: Mercurial-patchbomb
1607 Date: Thu, 01 Jan 1970 00:01:02 +0000
1624 Date: Thu, 01 Jan 1970 00:01:02 +0000
1608 From: quux
1625 From: quux
1609 To: foo
1626 To: foo
1610 Cc: bar
1627 Cc: bar
1611
1628
1612 # HG changeset patch
1629 # HG changeset patch
1613 # User test
1630 # User test
1614 # Date 2 0
1631 # Date 2 0
1615 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1632 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1616 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
1633 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
1617 b
1634 b
1618
1635
1619 diff -r 8580ff50825a -r 97d72e5f12c7 b
1636 diff -r 8580ff50825a -r 97d72e5f12c7 b
1620 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1637 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1621 +++ b/b Thu Jan 01 00:00:02 1970 +0000
1638 +++ b/b Thu Jan 01 00:00:02 1970 +0000
1622 @@ -0,0 +1,1 @@
1639 @@ -0,0 +1,1 @@
1623 +b
1640 +b
1624
1641
1625
1642
1626 test mutiple flags for single patch:
1643 test mutiple flags for single patch:
1627 $ hg email --date '1970-1-1 0:1' -n --flag fooFlag --flag barFlag -f quux -t foo \
1644 $ hg email --date '1970-1-1 0:1' -n --flag fooFlag --flag barFlag -f quux -t foo \
1628 > -c bar -s test -r 2 | fixheaders
1645 > -c bar -s test -r 2 | fixheaders
1629 This patch series consists of 1 patches.
1646 This patch series consists of 1 patches.
1630
1647
1631
1648
1632 Displaying [PATCH fooFlag barFlag] test ...
1649 Displaying [PATCH fooFlag barFlag] test ...
1633 Content-Type: text/plain; charset="us-ascii"
1650 Content-Type: text/plain; charset="us-ascii"
1634 MIME-Version: 1.0
1651 MIME-Version: 1.0
1635 Content-Transfer-Encoding: 7bit
1652 Content-Transfer-Encoding: 7bit
1636 Subject: [PATCH fooFlag barFlag] test
1653 Subject: [PATCH fooFlag barFlag] test
1637 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1654 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1638 Message-Id: <ff2c9fa2018b15fa74b3.60@
1655 Message-Id: <ff2c9fa2018b15fa74b3.60@
1639 User-Agent: Mercurial-patchbomb
1656 User-Agent: Mercurial-patchbomb
1640 Date: Thu, 01 Jan 1970 00:01:00 +0000
1657 Date: Thu, 01 Jan 1970 00:01:00 +0000
1641 From: quux
1658 From: quux
1642 To: foo
1659 To: foo
1643 Cc: bar
1660 Cc: bar
1644
1661
1645 # HG changeset patch
1662 # HG changeset patch
1646 # User test
1663 # User test
1647 # Date 3 0
1664 # Date 3 0
1648 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1665 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1649 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1666 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1650 c
1667 c
1651
1668
1652 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1669 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1653 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1670 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1654 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1671 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1655 @@ -0,0 +1,1 @@
1672 @@ -0,0 +1,1 @@
1656 +c
1673 +c
1657
1674
1658
1675
1659 test multiple flags for multiple patches:
1676 test multiple flags for multiple patches:
1660 $ hg email --date '1970-1-1 0:1' -n --flag fooFlag --flag barFlag -f quux -t foo \
1677 $ hg email --date '1970-1-1 0:1' -n --flag fooFlag --flag barFlag -f quux -t foo \
1661 > -c bar -s test -r 0:1 | fixheaders
1678 > -c bar -s test -r 0:1 | fixheaders
1662 This patch series consists of 2 patches.
1679 This patch series consists of 2 patches.
1663
1680
1664
1681
1665 Write the introductory message for the patch series.
1682 Write the introductory message for the patch series.
1666
1683
1667
1684
1668 Displaying [PATCH 0 of 2 fooFlag barFlag] test ...
1685 Displaying [PATCH 0 of 2 fooFlag barFlag] test ...
1669 Content-Type: text/plain; charset="us-ascii"
1686 Content-Type: text/plain; charset="us-ascii"
1670 MIME-Version: 1.0
1687 MIME-Version: 1.0
1671 Content-Transfer-Encoding: 7bit
1688 Content-Transfer-Encoding: 7bit
1672 Subject: [PATCH 0 of 2 fooFlag barFlag] test
1689 Subject: [PATCH 0 of 2 fooFlag barFlag] test
1673 Message-Id: <patchbomb.60@
1690 Message-Id: <patchbomb.60@
1674 User-Agent: Mercurial-patchbomb
1691 User-Agent: Mercurial-patchbomb
1675 Date: Thu, 01 Jan 1970 00:01:00 +0000
1692 Date: Thu, 01 Jan 1970 00:01:00 +0000
1676 From: quux
1693 From: quux
1677 To: foo
1694 To: foo
1678 Cc: bar
1695 Cc: bar
1679
1696
1680
1697
1681 Displaying [PATCH 1 of 2 fooFlag barFlag] a ...
1698 Displaying [PATCH 1 of 2 fooFlag barFlag] a ...
1682 Content-Type: text/plain; charset="us-ascii"
1699 Content-Type: text/plain; charset="us-ascii"
1683 MIME-Version: 1.0
1700 MIME-Version: 1.0
1684 Content-Transfer-Encoding: 7bit
1701 Content-Transfer-Encoding: 7bit
1685 Subject: [PATCH 1 of 2 fooFlag barFlag] a
1702 Subject: [PATCH 1 of 2 fooFlag barFlag] a
1686 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
1703 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
1687 Message-Id: <8580ff50825a50c8f716.61@
1704 Message-Id: <8580ff50825a50c8f716.61@
1688 In-Reply-To: <patchbomb.60@
1705 In-Reply-To: <patchbomb.60@
1689 References: <patchbomb.60@
1706 References: <patchbomb.60@
1690 User-Agent: Mercurial-patchbomb
1707 User-Agent: Mercurial-patchbomb
1691 Date: Thu, 01 Jan 1970 00:01:01 +0000
1708 Date: Thu, 01 Jan 1970 00:01:01 +0000
1692 From: quux
1709 From: quux
1693 To: foo
1710 To: foo
1694 Cc: bar
1711 Cc: bar
1695
1712
1696 # HG changeset patch
1713 # HG changeset patch
1697 # User test
1714 # User test
1698 # Date 1 0
1715 # Date 1 0
1699 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
1716 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
1700 # Parent 0000000000000000000000000000000000000000
1717 # Parent 0000000000000000000000000000000000000000
1701 a
1718 a
1702
1719
1703 diff -r 000000000000 -r 8580ff50825a a
1720 diff -r 000000000000 -r 8580ff50825a a
1704 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1721 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1705 +++ b/a Thu Jan 01 00:00:01 1970 +0000
1722 +++ b/a Thu Jan 01 00:00:01 1970 +0000
1706 @@ -0,0 +1,1 @@
1723 @@ -0,0 +1,1 @@
1707 +a
1724 +a
1708
1725
1709 Displaying [PATCH 2 of 2 fooFlag barFlag] b ...
1726 Displaying [PATCH 2 of 2 fooFlag barFlag] b ...
1710 Content-Type: text/plain; charset="us-ascii"
1727 Content-Type: text/plain; charset="us-ascii"
1711 MIME-Version: 1.0
1728 MIME-Version: 1.0
1712 Content-Transfer-Encoding: 7bit
1729 Content-Transfer-Encoding: 7bit
1713 Subject: [PATCH 2 of 2 fooFlag barFlag] b
1730 Subject: [PATCH 2 of 2 fooFlag barFlag] b
1714 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1731 X-Mercurial-Node: 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1715 Message-Id: <97d72e5f12c7e84f8506.62@
1732 Message-Id: <97d72e5f12c7e84f8506.62@
1716 In-Reply-To: <patchbomb.60@
1733 In-Reply-To: <patchbomb.60@
1717 References: <patchbomb.60@
1734 References: <patchbomb.60@
1718 User-Agent: Mercurial-patchbomb
1735 User-Agent: Mercurial-patchbomb
1719 Date: Thu, 01 Jan 1970 00:01:02 +0000
1736 Date: Thu, 01 Jan 1970 00:01:02 +0000
1720 From: quux
1737 From: quux
1721 To: foo
1738 To: foo
1722 Cc: bar
1739 Cc: bar
1723
1740
1724 # HG changeset patch
1741 # HG changeset patch
1725 # User test
1742 # User test
1726 # Date 2 0
1743 # Date 2 0
1727 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1744 # Node ID 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1728 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
1745 # Parent 8580ff50825a50c8f716709acdf8de0deddcd6ab
1729 b
1746 b
1730
1747
1731 diff -r 8580ff50825a -r 97d72e5f12c7 b
1748 diff -r 8580ff50825a -r 97d72e5f12c7 b
1732 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1749 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1733 +++ b/b Thu Jan 01 00:00:02 1970 +0000
1750 +++ b/b Thu Jan 01 00:00:02 1970 +0000
1734 @@ -0,0 +1,1 @@
1751 @@ -0,0 +1,1 @@
1735 +b
1752 +b
1736
1753
1737
1754
1738 test multi-address parsing:
1755 test multi-address parsing:
1739 $ hg email --date '1980-1-1 0:1' -m tmp.mbox -f quux -t 'spam<spam><eggs>' \
1756 $ hg email --date '1980-1-1 0:1' -m tmp.mbox -f quux -t 'spam<spam><eggs>' \
1740 > -t toast -c 'foo,bar@example.com' -c '"A, B <>" <a@example.com>' -s test -r 0 \
1757 > -t toast -c 'foo,bar@example.com' -c '"A, B <>" <a@example.com>' -s test -r 0 \
1741 > --config email.bcc='"Quux, A." <quux>'
1758 > --config email.bcc='"Quux, A." <quux>'
1742 This patch series consists of 1 patches.
1759 This patch series consists of 1 patches.
1743
1760
1744
1761
1745 Writing [PATCH] test ...
1762 Writing [PATCH] test ...
1746 $ fixheaders < tmp.mbox
1763 $ fixheaders < tmp.mbox
1747 From quux Tue Jan 01 00:01:01 1980
1764 From quux Tue Jan 01 00:01:01 1980
1748 Content-Type: text/plain; charset="us-ascii"
1765 Content-Type: text/plain; charset="us-ascii"
1749 MIME-Version: 1.0
1766 MIME-Version: 1.0
1750 Content-Transfer-Encoding: 7bit
1767 Content-Transfer-Encoding: 7bit
1751 Subject: [PATCH] test
1768 Subject: [PATCH] test
1752 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
1769 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
1753 Message-Id: <8580ff50825a50c8f716.315532860@
1770 Message-Id: <8580ff50825a50c8f716.315532860@
1754 User-Agent: Mercurial-patchbomb
1771 User-Agent: Mercurial-patchbomb
1755 Date: Tue, 01 Jan 1980 00:01:00 +0000
1772 Date: Tue, 01 Jan 1980 00:01:00 +0000
1756 From: quux
1773 From: quux
1757 To: spam <spam>, eggs, toast
1774 To: spam <spam>, eggs, toast
1758 Cc: foo, bar@example.com, "A, B <>" <a@example.com>
1775 Cc: foo, bar@example.com, "A, B <>" <a@example.com>
1759 Bcc: "Quux, A." <quux>
1776 Bcc: "Quux, A." <quux>
1760
1777
1761 # HG changeset patch
1778 # HG changeset patch
1762 # User test
1779 # User test
1763 # Date 1 0
1780 # Date 1 0
1764 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
1781 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
1765 # Parent 0000000000000000000000000000000000000000
1782 # Parent 0000000000000000000000000000000000000000
1766 a
1783 a
1767
1784
1768 diff -r 000000000000 -r 8580ff50825a a
1785 diff -r 000000000000 -r 8580ff50825a a
1769 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1786 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1770 +++ b/a Thu Jan 01 00:00:01 1970 +0000
1787 +++ b/a Thu Jan 01 00:00:01 1970 +0000
1771 @@ -0,0 +1,1 @@
1788 @@ -0,0 +1,1 @@
1772 +a
1789 +a
1773
1790
1774
1791
1775
1792
1776 test multi-byte domain parsing:
1793 test multi-byte domain parsing:
1777 $ UUML=`python -c 'import sys; sys.stdout.write("\374")'`
1794 $ UUML=`python -c 'import sys; sys.stdout.write("\374")'`
1778 $ HGENCODING=iso-8859-1
1795 $ HGENCODING=iso-8859-1
1779 $ export HGENCODING
1796 $ export HGENCODING
1780 $ hg email --date '1980-1-1 0:1' -m tmp.mbox -f quux -t "bar@${UUML}nicode.com" -s test -r 0
1797 $ hg email --date '1980-1-1 0:1' -m tmp.mbox -f quux -t "bar@${UUML}nicode.com" -s test -r 0
1781 This patch series consists of 1 patches.
1798 This patch series consists of 1 patches.
1782
1799
1783 Cc:
1800 Cc:
1784
1801
1785 Writing [PATCH] test ...
1802 Writing [PATCH] test ...
1786
1803
1787 $ cat tmp.mbox
1804 $ cat tmp.mbox
1788 From quux Tue Jan 01 00:01:01 1980
1805 From quux Tue Jan 01 00:01:01 1980
1789 Content-Type: text/plain; charset="us-ascii"
1806 Content-Type: text/plain; charset="us-ascii"
1790 MIME-Version: 1.0
1807 MIME-Version: 1.0
1791 Content-Transfer-Encoding: 7bit
1808 Content-Transfer-Encoding: 7bit
1792 Subject: [PATCH] test
1809 Subject: [PATCH] test
1793 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
1810 X-Mercurial-Node: 8580ff50825a50c8f716709acdf8de0deddcd6ab
1794 Message-Id: <8580ff50825a50c8f716.315532860@.*
1811 Message-Id: <8580ff50825a50c8f716.315532860@.*
1795 User-Agent: Mercurial-patchbomb/.*
1812 User-Agent: Mercurial-patchbomb/.*
1796 Date: Tue, 01 Jan 1980 00:01:00 +0000
1813 Date: Tue, 01 Jan 1980 00:01:00 +0000
1797 From: quux
1814 From: quux
1798 To: bar@xn--nicode-2ya.com
1815 To: bar@xn--nicode-2ya.com
1799
1816
1800 # HG changeset patch
1817 # HG changeset patch
1801 # User test
1818 # User test
1802 # Date 1 0
1819 # Date 1 0
1803 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
1820 # Node ID 8580ff50825a50c8f716709acdf8de0deddcd6ab
1804 # Parent 0000000000000000000000000000000000000000
1821 # Parent 0000000000000000000000000000000000000000
1805 a
1822 a
1806
1823
1807 diff -r 000000000000 -r 8580ff50825a a
1824 diff -r 000000000000 -r 8580ff50825a a
1808 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1825 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1809 +++ b/a Thu Jan 01 00:00:01 1970 +0000
1826 +++ b/a Thu Jan 01 00:00:01 1970 +0000
1810 @@ -0,0 +1,1 @@
1827 @@ -0,0 +1,1 @@
1811 +a
1828 +a
1812
1829
1813
1830
1814
1831
1815 test outgoing:
1832 test outgoing:
1816 $ hg up 1
1833 $ hg up 1
1817 0 files updated, 0 files merged, 6 files removed, 0 files unresolved
1834 0 files updated, 0 files merged, 6 files removed, 0 files unresolved
1818
1835
1819 $ hg branch test
1836 $ hg branch test
1820 marked working directory as branch test
1837 marked working directory as branch test
1821
1838
1822 $ echo d > d
1839 $ echo d > d
1823 $ hg add d
1840 $ hg add d
1824 $ hg ci -md -d '4 0'
1841 $ hg ci -md -d '4 0'
1825 $ hg email --date '1980-1-1 0:1' -n -t foo -s test -o ../t
1842 $ hg email --date '1980-1-1 0:1' -n -t foo -s test -o ../t
1826 comparing with ../t
1843 comparing with ../t
1827 searching for changes
1844 searching for changes
1828 From [test]: test
1845 From [test]: test
1829 This patch series consists of 8 patches.
1846 This patch series consists of 8 patches.
1830
1847
1831
1848
1832 Write the introductory message for the patch series.
1849 Write the introductory message for the patch series.
1833
1850
1834 Cc:
1851 Cc:
1835
1852
1836 Displaying [PATCH 0 of 8] test ...
1853 Displaying [PATCH 0 of 8] test ...
1837 Content-Type: text/plain; charset="us-ascii"
1854 Content-Type: text/plain; charset="us-ascii"
1838 MIME-Version: 1.0
1855 MIME-Version: 1.0
1839 Content-Transfer-Encoding: 7bit
1856 Content-Transfer-Encoding: 7bit
1840 Subject: [PATCH 0 of 8] test
1857 Subject: [PATCH 0 of 8] test
1841 Message-Id: <patchbomb.315532860@.*
1858 Message-Id: <patchbomb.315532860@.*
1842 User-Agent: Mercurial-patchbomb/.*
1859 User-Agent: Mercurial-patchbomb/.*
1843 Date: Tue, 01 Jan 1980 00:01:00 +0000
1860 Date: Tue, 01 Jan 1980 00:01:00 +0000
1844 From: test
1861 From: test
1845 To: foo
1862 To: foo
1846
1863
1847
1864
1848 Displaying [PATCH 1 of 8] c ...
1865 Displaying [PATCH 1 of 8] c ...
1849 Content-Type: text/plain; charset="us-ascii"
1866 Content-Type: text/plain; charset="us-ascii"
1850 MIME-Version: 1.0
1867 MIME-Version: 1.0
1851 Content-Transfer-Encoding: 7bit
1868 Content-Transfer-Encoding: 7bit
1852 Subject: [PATCH 1 of 8] c
1869 Subject: [PATCH 1 of 8] c
1853 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1870 X-Mercurial-Node: ff2c9fa2018b15fa74b33363bda9527323e2a99f
1854 Message-Id: <ff2c9fa2018b15fa74b3.315532861@.*
1871 Message-Id: <ff2c9fa2018b15fa74b3.315532861@.*
1855 In-Reply-To: <patchbomb.315532860@[^>]*>
1872 In-Reply-To: <patchbomb.315532860@[^>]*>
1856 References: <patchbomb.315532860@[^>]*>
1873 References: <patchbomb.315532860@[^>]*>
1857 User-Agent: Mercurial-patchbomb/.*
1874 User-Agent: Mercurial-patchbomb/.*
1858 Date: Tue, 01 Jan 1980 00:01:01 +0000
1875 Date: Tue, 01 Jan 1980 00:01:01 +0000
1859 From: test
1876 From: test
1860 To: foo
1877 To: foo
1861
1878
1862 # HG changeset patch
1879 # HG changeset patch
1863 # User test
1880 # User test
1864 # Date 3 0
1881 # Date 3 0
1865 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1882 # Node ID ff2c9fa2018b15fa74b33363bda9527323e2a99f
1866 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1883 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
1867 c
1884 c
1868
1885
1869 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1886 diff -r 97d72e5f12c7 -r ff2c9fa2018b c
1870 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1887 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1871 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1888 +++ b/c Thu Jan 01 00:00:03 1970 +0000
1872 @@ -0,0 +1,1 @@
1889 @@ -0,0 +1,1 @@
1873 +c
1890 +c
1874
1891
1875 Displaying [PATCH 2 of 8] charset=utf-8; content-transfer-encoding: base64 ...
1892 Displaying [PATCH 2 of 8] charset=utf-8; content-transfer-encoding: base64 ...
1876 Content-Type: text/plain; charset="us-ascii"
1893 Content-Type: text/plain; charset="us-ascii"
1877 MIME-Version: 1.0
1894 MIME-Version: 1.0
1878 Content-Transfer-Encoding: 8bit
1895 Content-Transfer-Encoding: 8bit
1879 Subject: [PATCH 2 of 8] charset=utf-8; content-transfer-encoding: base64
1896 Subject: [PATCH 2 of 8] charset=utf-8; content-transfer-encoding: base64
1880 X-Mercurial-Node: c3c9e37db9f4fe4882cda39baf42fed6bad8b15a
1897 X-Mercurial-Node: c3c9e37db9f4fe4882cda39baf42fed6bad8b15a
1881 Message-Id: <c3c9e37db9f4fe4882cd.315532862@.*
1898 Message-Id: <c3c9e37db9f4fe4882cd.315532862@.*
1882 In-Reply-To: <patchbomb.315532860@[^>]*>
1899 In-Reply-To: <patchbomb.315532860@[^>]*>
1883 References: <patchbomb.315532860@[^>]*>
1900 References: <patchbomb.315532860@[^>]*>
1884 User-Agent: Mercurial-patchbomb/.*
1901 User-Agent: Mercurial-patchbomb/.*
1885 Date: Tue, 01 Jan 1980 00:01:02 +0000
1902 Date: Tue, 01 Jan 1980 00:01:02 +0000
1886 From: test
1903 From: test
1887 To: foo
1904 To: foo
1888
1905
1889 # HG changeset patch
1906 # HG changeset patch
1890 # User test
1907 # User test
1891 # Date 4 0
1908 # Date 4 0
1892 # Node ID c3c9e37db9f4fe4882cda39baf42fed6bad8b15a
1909 # Node ID c3c9e37db9f4fe4882cda39baf42fed6bad8b15a
1893 # Parent ff2c9fa2018b15fa74b33363bda9527323e2a99f
1910 # Parent ff2c9fa2018b15fa74b33363bda9527323e2a99f
1894 charset=utf-8; content-transfer-encoding: base64
1911 charset=utf-8; content-transfer-encoding: base64
1895
1912
1896 diff -r ff2c9fa2018b -r c3c9e37db9f4 description
1913 diff -r ff2c9fa2018b -r c3c9e37db9f4 description
1897 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1914 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1898 +++ b/description Thu Jan 01 00:00:04 1970 +0000
1915 +++ b/description Thu Jan 01 00:00:04 1970 +0000
1899 @@ -0,0 +1,3 @@
1916 @@ -0,0 +1,3 @@
1900 +a multiline
1917 +a multiline
1901 +
1918 +
1902 +description
1919 +description
1903 diff -r ff2c9fa2018b -r c3c9e37db9f4 utf
1920 diff -r ff2c9fa2018b -r c3c9e37db9f4 utf
1904 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1921 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1905 +++ b/utf Thu Jan 01 00:00:04 1970 +0000
1922 +++ b/utf Thu Jan 01 00:00:04 1970 +0000
1906 @@ -0,0 +1,1 @@
1923 @@ -0,0 +1,1 @@
1907 +hΓΆmma!
1924 +hΓΆmma!
1908
1925
1909 Displaying [PATCH 3 of 8] charset=utf-8; content-transfer-encoding: quoted-printable ...
1926 Displaying [PATCH 3 of 8] charset=utf-8; content-transfer-encoding: quoted-printable ...
1910 Content-Type: text/plain; charset="us-ascii"
1927 Content-Type: text/plain; charset="us-ascii"
1911 MIME-Version: 1.0
1928 MIME-Version: 1.0
1912 Content-Transfer-Encoding: quoted-printable
1929 Content-Transfer-Encoding: quoted-printable
1913 Subject: [PATCH 3 of 8] charset=utf-8;
1930 Subject: [PATCH 3 of 8] charset=utf-8;
1914 content-transfer-encoding: quoted-printable
1931 content-transfer-encoding: quoted-printable
1915 X-Mercurial-Node: c655633f8c87700bb38cc6a59a2753bdc5a6c376
1932 X-Mercurial-Node: c655633f8c87700bb38cc6a59a2753bdc5a6c376
1916 Message-Id: <c655633f8c87700bb38c.315532863@.*
1933 Message-Id: <c655633f8c87700bb38c.315532863@.*
1917 In-Reply-To: <patchbomb.315532860@[^>]*>
1934 In-Reply-To: <patchbomb.315532860@[^>]*>
1918 References: <patchbomb.315532860@[^>]*>
1935 References: <patchbomb.315532860@[^>]*>
1919 User-Agent: Mercurial-patchbomb/.*
1936 User-Agent: Mercurial-patchbomb/.*
1920 Date: Tue, 01 Jan 1980 00:01:03 +0000
1937 Date: Tue, 01 Jan 1980 00:01:03 +0000
1921 From: test
1938 From: test
1922 To: foo
1939 To: foo
1923
1940
1924 # HG changeset patch
1941 # HG changeset patch
1925 # User test
1942 # User test
1926 # Date 4 0
1943 # Date 4 0
1927 # Node ID c655633f8c87700bb38cc6a59a2753bdc5a6c376
1944 # Node ID c655633f8c87700bb38cc6a59a2753bdc5a6c376
1928 # Parent c3c9e37db9f4fe4882cda39baf42fed6bad8b15a
1945 # Parent c3c9e37db9f4fe4882cda39baf42fed6bad8b15a
1929 charset=3Dutf-8; content-transfer-encoding: quoted-printable
1946 charset=3Dutf-8; content-transfer-encoding: quoted-printable
1930
1947
1931 diff -r c3c9e37db9f4 -r c655633f8c87 qp
1948 diff -r c3c9e37db9f4 -r c655633f8c87 qp
1932 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1949 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1933 +++ b/qp Thu Jan 01 00:00:04 1970 +0000
1950 +++ b/qp Thu Jan 01 00:00:04 1970 +0000
1934 @@ -0,0 +1,4 @@
1951 @@ -0,0 +1,4 @@
1935 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1952 +xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1936 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1953 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1937 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1954 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1938 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1955 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1939 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1956 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1940 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1957 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1941 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1958 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1942 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1959 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1943 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1960 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1944 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1961 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1945 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1962 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1946 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1963 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1947 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1964 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=
1948 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
1965 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
1949 +foo
1966 +foo
1950 +
1967 +
1951 +bar
1968 +bar
1952
1969
1953 Displaying [PATCH 4 of 8] charset=us-ascii; content-transfer-encoding: 8bit ...
1970 Displaying [PATCH 4 of 8] charset=us-ascii; content-transfer-encoding: 8bit ...
1954 Content-Type: text/plain; charset="us-ascii"
1971 Content-Type: text/plain; charset="us-ascii"
1955 MIME-Version: 1.0
1972 MIME-Version: 1.0
1956 Content-Transfer-Encoding: 8bit
1973 Content-Transfer-Encoding: 8bit
1957 Subject: [PATCH 4 of 8] charset=us-ascii; content-transfer-encoding: 8bit
1974 Subject: [PATCH 4 of 8] charset=us-ascii; content-transfer-encoding: 8bit
1958 X-Mercurial-Node: 22d0f96be12f5945fd67d101af58f7bc8263c835
1975 X-Mercurial-Node: 22d0f96be12f5945fd67d101af58f7bc8263c835
1959 Message-Id: <22d0f96be12f5945fd67.315532864@.*
1976 Message-Id: <22d0f96be12f5945fd67.315532864@.*
1960 In-Reply-To: <patchbomb.315532860@[^>]*>
1977 In-Reply-To: <patchbomb.315532860@[^>]*>
1961 References: <patchbomb.315532860@[^>]*>
1978 References: <patchbomb.315532860@[^>]*>
1962 User-Agent: Mercurial-patchbomb/.*
1979 User-Agent: Mercurial-patchbomb/.*
1963 Date: Tue, 01 Jan 1980 00:01:04 +0000
1980 Date: Tue, 01 Jan 1980 00:01:04 +0000
1964 From: test
1981 From: test
1965 To: foo
1982 To: foo
1966
1983
1967 # HG changeset patch
1984 # HG changeset patch
1968 # User test
1985 # User test
1969 # Date 5 0
1986 # Date 5 0
1970 # Node ID 22d0f96be12f5945fd67d101af58f7bc8263c835
1987 # Node ID 22d0f96be12f5945fd67d101af58f7bc8263c835
1971 # Parent c655633f8c87700bb38cc6a59a2753bdc5a6c376
1988 # Parent c655633f8c87700bb38cc6a59a2753bdc5a6c376
1972 charset=us-ascii; content-transfer-encoding: 8bit
1989 charset=us-ascii; content-transfer-encoding: 8bit
1973
1990
1974 diff -r c655633f8c87 -r 22d0f96be12f isolatin
1991 diff -r c655633f8c87 -r 22d0f96be12f isolatin
1975 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1992 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1976 +++ b/isolatin Thu Jan 01 00:00:05 1970 +0000
1993 +++ b/isolatin Thu Jan 01 00:00:05 1970 +0000
1977 @@ -0,0 +1,1 @@
1994 @@ -0,0 +1,1 @@
1978 +hοΏ½mma!
1995 +hοΏ½mma!
1979
1996
1980 Displaying [PATCH 5 of 8] Added tag zero, zero.foo for changeset 8580ff50825a ...
1997 Displaying [PATCH 5 of 8] Added tag zero, zero.foo for changeset 8580ff50825a ...
1981 Content-Type: text/plain; charset="us-ascii"
1998 Content-Type: text/plain; charset="us-ascii"
1982 MIME-Version: 1.0
1999 MIME-Version: 1.0
1983 Content-Transfer-Encoding: 7bit
2000 Content-Transfer-Encoding: 7bit
1984 Subject: [PATCH 5 of 8] Added tag zero, zero.foo for changeset 8580ff50825a
2001 Subject: [PATCH 5 of 8] Added tag zero, zero.foo for changeset 8580ff50825a
1985 X-Mercurial-Node: dd9c2b4b8a8a0934d5523c15f2c119b362360903
2002 X-Mercurial-Node: dd9c2b4b8a8a0934d5523c15f2c119b362360903
1986 Message-Id: <dd9c2b4b8a8a0934d552.315532865@.*
2003 Message-Id: <dd9c2b4b8a8a0934d552.315532865@.*
1987 In-Reply-To: <patchbomb.315532860@[^>]*>
2004 In-Reply-To: <patchbomb.315532860@[^>]*>
1988 References: <patchbomb.315532860@[^>]*>
2005 References: <patchbomb.315532860@[^>]*>
1989 User-Agent: Mercurial-patchbomb/.*
2006 User-Agent: Mercurial-patchbomb/.*
1990 Date: Tue, 01 Jan 1980 00:01:05 +0000
2007 Date: Tue, 01 Jan 1980 00:01:05 +0000
1991 From: test
2008 From: test
1992 To: foo
2009 To: foo
1993
2010
1994 # HG changeset patch
2011 # HG changeset patch
1995 # User test
2012 # User test
1996 # Date 0 0
2013 # Date 0 0
1997 # Node ID dd9c2b4b8a8a0934d5523c15f2c119b362360903
2014 # Node ID dd9c2b4b8a8a0934d5523c15f2c119b362360903
1998 # Parent 22d0f96be12f5945fd67d101af58f7bc8263c835
2015 # Parent 22d0f96be12f5945fd67d101af58f7bc8263c835
1999 Added tag zero, zero.foo for changeset 8580ff50825a
2016 Added tag zero, zero.foo for changeset 8580ff50825a
2000
2017
2001 diff -r 22d0f96be12f -r dd9c2b4b8a8a .hgtags
2018 diff -r 22d0f96be12f -r dd9c2b4b8a8a .hgtags
2002 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2019 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2003 +++ b/.hgtags Thu Jan 01 00:00:00 1970 +0000
2020 +++ b/.hgtags Thu Jan 01 00:00:00 1970 +0000
2004 @@ -0,0 +1,2 @@
2021 @@ -0,0 +1,2 @@
2005 +8580ff50825a50c8f716709acdf8de0deddcd6ab zero
2022 +8580ff50825a50c8f716709acdf8de0deddcd6ab zero
2006 +8580ff50825a50c8f716709acdf8de0deddcd6ab zero.foo
2023 +8580ff50825a50c8f716709acdf8de0deddcd6ab zero.foo
2007
2024
2008 Displaying [PATCH 6 of 8] Added tag one, one.patch for changeset 97d72e5f12c7 ...
2025 Displaying [PATCH 6 of 8] Added tag one, one.patch for changeset 97d72e5f12c7 ...
2009 Content-Type: text/plain; charset="us-ascii"
2026 Content-Type: text/plain; charset="us-ascii"
2010 MIME-Version: 1.0
2027 MIME-Version: 1.0
2011 Content-Transfer-Encoding: 7bit
2028 Content-Transfer-Encoding: 7bit
2012 Subject: [PATCH 6 of 8] Added tag one, one.patch for changeset 97d72e5f12c7
2029 Subject: [PATCH 6 of 8] Added tag one, one.patch for changeset 97d72e5f12c7
2013 X-Mercurial-Node: eae5fcf795eee29d0e45ffc9f519a91cd79fc9ff
2030 X-Mercurial-Node: eae5fcf795eee29d0e45ffc9f519a91cd79fc9ff
2014 Message-Id: <eae5fcf795eee29d0e45.315532866@.*
2031 Message-Id: <eae5fcf795eee29d0e45.315532866@.*
2015 In-Reply-To: <patchbomb.315532860@[^>]*>
2032 In-Reply-To: <patchbomb.315532860@[^>]*>
2016 References: <patchbomb.315532860@[^>]*>
2033 References: <patchbomb.315532860@[^>]*>
2017 User-Agent: Mercurial-patchbomb/.*
2034 User-Agent: Mercurial-patchbomb/.*
2018 Date: Tue, 01 Jan 1980 00:01:06 +0000
2035 Date: Tue, 01 Jan 1980 00:01:06 +0000
2019 From: test
2036 From: test
2020 To: foo
2037 To: foo
2021
2038
2022 # HG changeset patch
2039 # HG changeset patch
2023 # User test
2040 # User test
2024 # Date 0 0
2041 # Date 0 0
2025 # Node ID eae5fcf795eee29d0e45ffc9f519a91cd79fc9ff
2042 # Node ID eae5fcf795eee29d0e45ffc9f519a91cd79fc9ff
2026 # Parent dd9c2b4b8a8a0934d5523c15f2c119b362360903
2043 # Parent dd9c2b4b8a8a0934d5523c15f2c119b362360903
2027 Added tag one, one.patch for changeset 97d72e5f12c7
2044 Added tag one, one.patch for changeset 97d72e5f12c7
2028
2045
2029 diff -r dd9c2b4b8a8a -r eae5fcf795ee .hgtags
2046 diff -r dd9c2b4b8a8a -r eae5fcf795ee .hgtags
2030 --- a/.hgtags Thu Jan 01 00:00:00 1970 +0000
2047 --- a/.hgtags Thu Jan 01 00:00:00 1970 +0000
2031 +++ b/.hgtags Thu Jan 01 00:00:00 1970 +0000
2048 +++ b/.hgtags Thu Jan 01 00:00:00 1970 +0000
2032 @@ -1,2 +1,4 @@
2049 @@ -1,2 +1,4 @@
2033 8580ff50825a50c8f716709acdf8de0deddcd6ab zero
2050 8580ff50825a50c8f716709acdf8de0deddcd6ab zero
2034 8580ff50825a50c8f716709acdf8de0deddcd6ab zero.foo
2051 8580ff50825a50c8f716709acdf8de0deddcd6ab zero.foo
2035 +97d72e5f12c7e84f85064aa72e5a297142c36ed9 one
2052 +97d72e5f12c7e84f85064aa72e5a297142c36ed9 one
2036 +97d72e5f12c7e84f85064aa72e5a297142c36ed9 one.patch
2053 +97d72e5f12c7e84f85064aa72e5a297142c36ed9 one.patch
2037
2054
2038 Displaying [PATCH 7 of 8] Added tag two, two.diff for changeset ff2c9fa2018b ...
2055 Displaying [PATCH 7 of 8] Added tag two, two.diff for changeset ff2c9fa2018b ...
2039 Content-Type: text/plain; charset="us-ascii"
2056 Content-Type: text/plain; charset="us-ascii"
2040 MIME-Version: 1.0
2057 MIME-Version: 1.0
2041 Content-Transfer-Encoding: 7bit
2058 Content-Transfer-Encoding: 7bit
2042 Subject: [PATCH 7 of 8] Added tag two, two.diff for changeset ff2c9fa2018b
2059 Subject: [PATCH 7 of 8] Added tag two, two.diff for changeset ff2c9fa2018b
2043 X-Mercurial-Node: e317db6a6f288748d1f6cb064f3810fcba66b1b6
2060 X-Mercurial-Node: e317db6a6f288748d1f6cb064f3810fcba66b1b6
2044 Message-Id: <e317db6a6f288748d1f6.315532867@.*
2061 Message-Id: <e317db6a6f288748d1f6.315532867@.*
2045 In-Reply-To: <patchbomb.315532860@[^>]*>
2062 In-Reply-To: <patchbomb.315532860@[^>]*>
2046 References: <patchbomb.315532860@[^>]*>
2063 References: <patchbomb.315532860@[^>]*>
2047 User-Agent: Mercurial-patchbomb/.*
2064 User-Agent: Mercurial-patchbomb/.*
2048 Date: Tue, 01 Jan 1980 00:01:07 +0000
2065 Date: Tue, 01 Jan 1980 00:01:07 +0000
2049 From: test
2066 From: test
2050 To: foo
2067 To: foo
2051
2068
2052 # HG changeset patch
2069 # HG changeset patch
2053 # User test
2070 # User test
2054 # Date 0 0
2071 # Date 0 0
2055 # Node ID e317db6a6f288748d1f6cb064f3810fcba66b1b6
2072 # Node ID e317db6a6f288748d1f6cb064f3810fcba66b1b6
2056 # Parent eae5fcf795eee29d0e45ffc9f519a91cd79fc9ff
2073 # Parent eae5fcf795eee29d0e45ffc9f519a91cd79fc9ff
2057 Added tag two, two.diff for changeset ff2c9fa2018b
2074 Added tag two, two.diff for changeset ff2c9fa2018b
2058
2075
2059 diff -r eae5fcf795ee -r e317db6a6f28 .hgtags
2076 diff -r eae5fcf795ee -r e317db6a6f28 .hgtags
2060 --- a/.hgtags Thu Jan 01 00:00:00 1970 +0000
2077 --- a/.hgtags Thu Jan 01 00:00:00 1970 +0000
2061 +++ b/.hgtags Thu Jan 01 00:00:00 1970 +0000
2078 +++ b/.hgtags Thu Jan 01 00:00:00 1970 +0000
2062 @@ -2,3 +2,5 @@
2079 @@ -2,3 +2,5 @@
2063 8580ff50825a50c8f716709acdf8de0deddcd6ab zero.foo
2080 8580ff50825a50c8f716709acdf8de0deddcd6ab zero.foo
2064 97d72e5f12c7e84f85064aa72e5a297142c36ed9 one
2081 97d72e5f12c7e84f85064aa72e5a297142c36ed9 one
2065 97d72e5f12c7e84f85064aa72e5a297142c36ed9 one.patch
2082 97d72e5f12c7e84f85064aa72e5a297142c36ed9 one.patch
2066 +ff2c9fa2018b15fa74b33363bda9527323e2a99f two
2083 +ff2c9fa2018b15fa74b33363bda9527323e2a99f two
2067 +ff2c9fa2018b15fa74b33363bda9527323e2a99f two.diff
2084 +ff2c9fa2018b15fa74b33363bda9527323e2a99f two.diff
2068
2085
2069 Displaying [PATCH 8 of 8] d ...
2086 Displaying [PATCH 8 of 8] d ...
2070 Content-Type: text/plain; charset="us-ascii"
2087 Content-Type: text/plain; charset="us-ascii"
2071 MIME-Version: 1.0
2088 MIME-Version: 1.0
2072 Content-Transfer-Encoding: 7bit
2089 Content-Transfer-Encoding: 7bit
2073 Subject: [PATCH 8 of 8] d
2090 Subject: [PATCH 8 of 8] d
2074 X-Mercurial-Node: 2f9fa9b998c5fe3ac2bd9a2b14bfcbeecbc7c268
2091 X-Mercurial-Node: 2f9fa9b998c5fe3ac2bd9a2b14bfcbeecbc7c268
2075 Message-Id: <2f9fa9b998c5fe3ac2bd.315532868[^>]*>
2092 Message-Id: <2f9fa9b998c5fe3ac2bd.315532868[^>]*>
2076 In-Reply-To: <patchbomb.315532860@[^>]*>
2093 In-Reply-To: <patchbomb.315532860@[^>]*>
2077 References: <patchbomb.315532860@[^>]*>
2094 References: <patchbomb.315532860@[^>]*>
2078 User-Agent: Mercurial-patchbomb/.*
2095 User-Agent: Mercurial-patchbomb/.*
2079 Date: Tue, 01 Jan 1980 00:01:08 +0000
2096 Date: Tue, 01 Jan 1980 00:01:08 +0000
2080 From: test
2097 From: test
2081 To: foo
2098 To: foo
2082
2099
2083 # HG changeset patch
2100 # HG changeset patch
2084 # User test
2101 # User test
2085 # Date 4 0
2102 # Date 4 0
2086 # Branch test
2103 # Branch test
2087 # Node ID 2f9fa9b998c5fe3ac2bd9a2b14bfcbeecbc7c268
2104 # Node ID 2f9fa9b998c5fe3ac2bd9a2b14bfcbeecbc7c268
2088 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2105 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2089 d
2106 d
2090
2107
2091 diff -r 97d72e5f12c7 -r 2f9fa9b998c5 d
2108 diff -r 97d72e5f12c7 -r 2f9fa9b998c5 d
2092 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2109 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2093 +++ b/d Thu Jan 01 00:00:04 1970 +0000
2110 +++ b/d Thu Jan 01 00:00:04 1970 +0000
2094 @@ -0,0 +1,1 @@
2111 @@ -0,0 +1,1 @@
2095 +d
2112 +d
2096
2113
2097
2114
2098 dest#branch URIs:
2115 dest#branch URIs:
2099 $ hg email --date '1980-1-1 0:1' -n -t foo -s test -o ../t#test
2116 $ hg email --date '1980-1-1 0:1' -n -t foo -s test -o ../t#test
2100 comparing with ../t
2117 comparing with ../t
2101 searching for changes
2118 searching for changes
2102 From [test]: test
2119 From [test]: test
2103 This patch series consists of 1 patches.
2120 This patch series consists of 1 patches.
2104
2121
2105 Cc:
2122 Cc:
2106
2123
2107 Displaying [PATCH] test ...
2124 Displaying [PATCH] test ...
2108 Content-Type: text/plain; charset="us-ascii"
2125 Content-Type: text/plain; charset="us-ascii"
2109 MIME-Version: 1.0
2126 MIME-Version: 1.0
2110 Content-Transfer-Encoding: 7bit
2127 Content-Transfer-Encoding: 7bit
2111 Subject: [PATCH] test
2128 Subject: [PATCH] test
2112 X-Mercurial-Node: 2f9fa9b998c5fe3ac2bd9a2b14bfcbeecbc7c268
2129 X-Mercurial-Node: 2f9fa9b998c5fe3ac2bd9a2b14bfcbeecbc7c268
2113 Message-Id: <2f9fa9b998c5fe3ac2bd.315532860@.*
2130 Message-Id: <2f9fa9b998c5fe3ac2bd.315532860@.*
2114 User-Agent: Mercurial-patchbomb/.*
2131 User-Agent: Mercurial-patchbomb/.*
2115 Date: Tue, 01 Jan 1980 00:01:00 +0000
2132 Date: Tue, 01 Jan 1980 00:01:00 +0000
2116 From: test
2133 From: test
2117 To: foo
2134 To: foo
2118
2135
2119 # HG changeset patch
2136 # HG changeset patch
2120 # User test
2137 # User test
2121 # Date 4 0
2138 # Date 4 0
2122 # Branch test
2139 # Branch test
2123 # Node ID 2f9fa9b998c5fe3ac2bd9a2b14bfcbeecbc7c268
2140 # Node ID 2f9fa9b998c5fe3ac2bd9a2b14bfcbeecbc7c268
2124 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2141 # Parent 97d72e5f12c7e84f85064aa72e5a297142c36ed9
2125 d
2142 d
2126
2143
2127 diff -r 97d72e5f12c7 -r 2f9fa9b998c5 d
2144 diff -r 97d72e5f12c7 -r 2f9fa9b998c5 d
2128 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2145 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2129 +++ b/d Thu Jan 01 00:00:04 1970 +0000
2146 +++ b/d Thu Jan 01 00:00:04 1970 +0000
2130 @@ -0,0 +1,1 @@
2147 @@ -0,0 +1,1 @@
2131 +d
2148 +d
2132
2149
General Comments 0
You need to be logged in to leave comments. Login now