Cache settings and removing unused files.