Making preferences.d directory before writing into it