Automatic cleanup of repository after startup.