MCPcopy Create free account
hub / github.com/OpenMW/UIX-R / validate

Function validate

validate_uix.py:38–81  ·  view source on GitHub ↗
(md5_list)

Source from the content-addressed store, hash-verified

36
37
38def validate(md5_list):
39 print("\nComparing md5sum of UIX:R to the other files.")
40 beth_counter = starboi_counter = vurt_counter = jarvik_counter = glory_counter = ules_counter = 0
41 for line in md5_list.split('\n'):
42 if len(line) > 0:
43 md5, rest = line.split(",", 1)
44 if md5 in morrowind_md5:
45 beth_counter += 1
46 print("{0},{1},Found in Morrowind.bsa".format(md5, rest))
47 if md5 in tribunal_md5:
48 beth_counter += 1
49 print("{0},{1},Found in Tribunal.bsa".format(md5, rest))
50 if md5 in bloodmoon_md5:
51 beth_counter += 1
52 print("{0},{1},Found in Bloodmoon.bsa".format(md5, rest))
53 if md5 in starboi_md5:
54 starboi_counter += 1
55 print("{0},{1},Found in StarBoi's work".format(md5, rest))
56 if md5 in vurt_md5:
57 vurt_counter += 1
58 print("{0},{1},Found in Vurt's work".format(md5, rest))
59 if md5 in jarvik_md5:
60 jarvik_counter += 1
61 print("{0},{1},Found in Jarvik bsa".format(md5, rest))
62 if md5 in glory_md5:
63 glory_counter += 1
64 print("{0},{1},Found in TheGloryRoad".format(md5, rest))
65 if md5 in ules_md5:
66 ules_counter += 1
67 print("{0},{1},Found in Ules' Farm".format(md5, rest))
68
69 total = beth_counter + starboi_counter + vurt_counter + jarvik_counter + glory_counter + \
70 ules_counter
71
72 print("""\
73Out of {0} files, found: {1}
74 {2} bethesda files
75 {3} starboi files
76 {4} vurt files
77 {5} jarvik files
78 {6} glory files
79 {7} ules files""".format(
80 len(md5_list.split('\n'))-1, total, beth_counter, starboi_counter, vurt_counter,
81 jarvik_counter, glory_counter, ules_counter))
82
83
84# uixr files

Callers 1

validate_uix.pyFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected