189
189
self.reporter = reporter
190
190
self.config = config
193
def update_revprops(revprops, branch, authors=None, author=None,
194
local=False, possible_master_transports=None):
197
if possible_master_transports is None:
198
possible_master_transports = []
199
if not 'branch-nick' in revprops:
200
revprops['branch-nick'] = branch._get_nick(
202
possible_master_transports)
203
if authors is not None:
204
if author is not None:
205
raise AssertionError('Specifying both author and authors '
206
'is not allowed. Specify just authors instead')
207
if 'author' in revprops or 'authors' in revprops:
208
# XXX: maybe we should just accept one of them?
209
raise AssertionError('author property given twice')
211
for individual in authors:
212
if '\n' in individual:
213
raise AssertionError('\\n is not a valid character '
214
'in an author identity')
215
revprops['authors'] = '\n'.join(authors)
216
if author is not None:
217
symbol_versioning.warn('The parameter author was deprecated'
218
' in version 1.13. Use authors instead',
220
if 'author' in revprops or 'authors' in revprops:
221
# XXX: maybe we should just accept one of them?
222
raise AssertionError('author property given twice')
224
raise AssertionError('\\n is not a valid character '
225
'in an author identity')
226
revprops['authors'] = author