2 __date__ =
"$2010-08-13 14.28.08$" 7 from os.path
import join, split
11 if sys.platform[:3] ==
'win':
20 picFiles = sorted(glob.glob(
join(directory,
"cmsCodeRule*.dat")))
23 head, fileName =
split(file)
24 ruleName = fileName[11:-4]
25 rulesNames.append(ruleName)
27 file = open(file,
'rb')
28 ruleResult = pickle.load(file)
32 rulesResults[ruleName] = ruleResult
42 if not ruleResult:
return info
44 ruleResult = sorted(ruleResult.items())
45 file, lines = ruleResult.pop(0)
47 package = slash.join(pathList[:2])
48 packageResult.append((slash.join(pathList[2:]), lines))
50 for file, lines
in ruleResult:
52 head = slash.join(pathList[:2])
53 tail = slash.join(pathList[2:])
55 packageResult.append((tail, lines))
57 info.append((package, packageResult))
60 packageResult.append((tail, lines))
61 info.append((package, packageResult))
66 head, tail =
split(path)
70 head, tail =
split(head)
def splitToPackages(ruleResult)
def split(sequence, size)
static std::string join(char **cmd)
def readPicFiles(directory, toSplit=False)