Make writing to file user-controlable