write expansion file