Simplify file writing.