files = [f for f in files if any(f.startswith(m) for m in accepted_files)]