Remove references to files we don't want to follow