comparison contrib/synthrepo.py @ 32291:bd872f64a8ba

cleanup: use set literals We no longer support Python 2.6, so we can now use set literals.
author Martin von Zweigbergk <martinvonz@google.com>
date Fri, 10 Feb 2017 16:56:29 -0800
parents d5883fd055c6
children 46ba2cdda476
comparison
equal deleted inserted replaced
32290:2959c3e986e0 32291:bd872f64a8ba
69 testedwith = 'ships-with-hg-core' 69 testedwith = 'ships-with-hg-core'
70 70
71 cmdtable = {} 71 cmdtable = {}
72 command = cmdutil.command(cmdtable) 72 command = cmdutil.command(cmdtable)
73 73
74 newfile = set(('new fi', 'rename', 'copy f', 'copy t')) 74 newfile = {'new fi', 'rename', 'copy f', 'copy t'}
75 75
76 def zerodict(): 76 def zerodict():
77 return collections.defaultdict(lambda: 0) 77 return collections.defaultdict(lambda: 0)
78 78
79 def roundto(x, k): 79 def roundto(x, k):
334 return ' '.join(l) 334 return ' '.join(l)
335 335
336 wlock = repo.wlock() 336 wlock = repo.wlock()
337 lock = repo.lock() 337 lock = repo.lock()
338 338
339 nevertouch = set(('.hgsub', '.hgignore', '.hgtags')) 339 nevertouch = {'.hgsub', '.hgignore', '.hgtags'}
340 340
341 progress = ui.progress 341 progress = ui.progress
342 _synthesizing = _('synthesizing') 342 _synthesizing = _('synthesizing')
343 _files = _('initial files') 343 _files = _('initial files')
344 _changesets = _('changesets') 344 _changesets = _('changesets')