switched to regex for checking hidden files