#!/usr/bin/env escript %%! -noshell main(_) -> Files = filelib:wildcard("apps/game_server/cache_recovered_grouped/*.table"), Bad = [{F, E} || F <- Files, {error, E} <- [file:consult(F)]], io:format("files=~p bad_count=~p~n", [length(Files), length(Bad)]), case Bad of [] -> halt(0); _ -> io:format("~p~n", [Bad]), halt(1) end.