File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 55
66import json
77import os
8+ import progressbar
9+
810
911path = "../entries/"
1012games_list = os .listdir (path )
1113
12- for game in games_list :
13-
14+ for game in progressbar .progressbar (games_list , redirect_stdout = True ):
1415 with open (f"../entries/{ game } /game.json" ) as f :
1516 game = json .load (f )
1617 print (f"Checking { game ['slug' ]} .." )
1718 for file in game ["files" ]:
1819 if file ["filename" ] not in os .listdir (f"{ path } /{ game ['slug' ]} " ):
19- raise Exception (f'{ file ["filename" ]} found in manifest but not on disk (entry { game ["slug" ]} )' )
20+ raise Exception (
21+ f'{ file ["filename" ]} found in manifest but not on disk (entry { game ["slug" ]} )'
22+ )
2023 for screenshot in game ["screenshots" ]:
2124 if screenshot not in os .listdir (f"{ path } /{ game ['slug' ]} " ):
22- raise Exception (f'{ screenshot } found in manifest but not on disk (entry { game ["slug" ]} )' )
23- print (f"{ game ['slug' ]} : { len (game ['files' ])} file(s), { len (game ['screenshots' ])} screenshot(s)" )
25+ raise Exception (
26+ f'{ screenshot } found in manifest but not on disk (entry { game ["slug" ]} )'
27+ )
28+ print (
29+ f"{ game ['slug' ]} : { len (game ['files' ])} file(s), { len (game ['screenshots' ])} screenshot(s)"
30+ )
You can’t perform that action at this time.
0 commit comments