helps in logging all the logs to a text file