mirror of
https://github.com/ParticulateFlow/LPP.git
synced 2025-12-08 06:37:46 +00:00
Merge pull request #2 from aaigner/master
Lpp for Windows: Wildcard can be used to input dump-files in CMD
This commit is contained in:
11
src/lpp.py
11
src/lpp.py
@ -74,7 +74,16 @@ class lpp:
|
||||
if self.debugMode: print "number of process:", os.getpid()
|
||||
|
||||
# check whether file-list is nonempty
|
||||
self.flist = list[0]
|
||||
self.flist = []
|
||||
# get file list for windows
|
||||
if os.name == 'nt':
|
||||
for item in list[0]:
|
||||
if '*' in item: # interpret wildcard with glob()
|
||||
self.flist = self.flist + glob.glob(list[0][0])
|
||||
else:
|
||||
self.flist = self.flist + [item]
|
||||
else: # unix: the input should be a valid list
|
||||
self.flist = list[0]
|
||||
listlen = len(self.flist)
|
||||
if listlen == 0 and len(list) == 1:
|
||||
raise StandardError, "no dump file specified"
|
||||
|
||||
Reference in New Issue
Block a user