write new config with changes