# Try to create pairs
appPairs = []
+useSecondList = False
# Extract the second list if provided (this is for combinations between two lists)
if (len(sys.argv) == 6):
secondList = sys.argv[5]
if '#' not in app:
appList2.append(app.strip())
extractAppList.close()
+ useSecondList = True
# Just copy the first list to the second list
else:
appList2 = appList1
-# Generate the permutations of pairs
-for i in range(len(appList1)):
- for j in range(i + 1, len(appList2)):
- appPairs.append((appList1[i], appList2[j]))
-
+if useSecondList is False:
+ # Generate the permutations of pairs
+ for i in range(len(appList1)):
+ for j in range(i + 1, len(appList2)):
+ appPairs.append((appList1[i], appList2[j]))
+else:
+ # Generate pairs from 2 lists
+ for i in range(len(appList1)):
+ for j in range(len(appList2)):
+ appPairs.append((appList1[i], appList2[j]))
+
# PART 2:
print "PHASE 2: Running JPF ...\n"
# List down all the log file names