comparison hgext/largefiles/lfutil.py @ 25149:3f0744eeaeaf

cleanup: use __builtins__.any instead of util.any any() is available in all Python versions we support now.
author Augie Fackler <augie@google.com>
date Sat, 16 May 2015 14:30:07 -0400
parents 2a3f24786d09
children 85f1aaf18ecb
comparison
equal deleted inserted replaced
25148:3b5cd6f13dcc 25149:3f0744eeaeaf
362 '''Return a version of path normalized for use with the lfdirstate.''' 362 '''Return a version of path normalized for use with the lfdirstate.'''
363 return util.pconvert(os.path.normpath(path)) 363 return util.pconvert(os.path.normpath(path))
364 364
365 def islfilesrepo(repo): 365 def islfilesrepo(repo):
366 if ('largefiles' in repo.requirements and 366 if ('largefiles' in repo.requirements and
367 util.any(shortnameslash in f[0] for f in repo.store.datafiles())): 367 any(shortnameslash in f[0] for f in repo.store.datafiles())):
368 return True 368 return True
369 369
370 return util.any(openlfdirstate(repo.ui, repo, False)) 370 return any(openlfdirstate(repo.ui, repo, False))
371 371
372 class storeprotonotcapable(Exception): 372 class storeprotonotcapable(Exception):
373 def __init__(self, storetypes): 373 def __init__(self, storetypes):
374 self.storetypes = storetypes 374 self.storetypes = storetypes
375 375