Implemented saving a config file to a TextWriter