Start encapsulating the steps for writing to files