Change the retry logic to write a limit file, able to source limit from files by indicating with @filename

This commit is contained in:
Michael DeHaan 2013-04-08 12:36:01 -04:00
commit 0d530f3bf0
3 changed files with 25 additions and 67 deletions

View file

@ -330,7 +330,17 @@ class Inventory(object):
self._subset = None
else:
subset_pattern = subset_pattern.replace(',',':')
self._subset = subset_pattern.replace(";",":").split(":")
subset_pattern = subset_pattern.replace(";",":").split(":")
results = []
# allow Unix style @filename data
for x in subset_pattern:
if x.startswith("@"):
fd = open(x[1:])
results.extend(fd.read().split("\n"))
fd.close()
else:
results.append(x)
self._subset = results
def lift_restriction(self):
""" Do not restrict list operations """