##// END OF EJS Templates
rename [patchbomb] section to [email] section in hgrc. old name still ok.
Vadim Gelfer -
r2198:56403455 default
parent child Browse files
Show More
@@ -44,7 +44,7 b''
44 # To configure other defaults, add a section like this to your hgrc
44 # To configure other defaults, add a section like this to your hgrc
45 # file:
45 # file:
46 #
46 #
47 # [patchbomb]
47 # [email]
48 # from = My Name <my@email>
48 # from = My Name <my@email>
49 # to = recipient1, recipient2, ...
49 # to = recipient1, recipient2, ...
50 # cc = cc1, cc2, ...
50 # cc = cc1, cc2, ...
@@ -183,11 +183,13 b' def patchbomb(ui, repo, *revs, **opts):'
183 jumbo.extend(p)
183 jumbo.extend(p)
184 msgs.append(makepatch(p, i + 1, len(patches)))
184 msgs.append(makepatch(p, i + 1, len(patches)))
185
185
186 sender = (opts['from'] or ui.config('patchbomb', 'from') or
186 sender = (opts['from'] or ui.config('email', 'from') or
187 ui.config('patchbomb', 'from') or
187 prompt('From', ui.username()))
188 prompt('From', ui.username()))
188
189
189 def getaddrs(opt, prpt, default = None):
190 def getaddrs(opt, prpt, default = None):
190 addrs = opts[opt] or (ui.config('patchbomb', opt) or
191 addrs = opts[opt] or (ui.config('email', opt) or
192 ui.config('patchbomb', opt) or
191 prompt(prpt, default = default)).split(',')
193 prompt(prpt, default = default)).split(',')
192 return [a.strip() for a in addrs if a.strip()]
194 return [a.strip() for a in addrs if a.strip()]
193 to = getaddrs('to', 'To')
195 to = getaddrs('to', 'To')
General Comments 0
You need to be logged in to leave comments. Login now