loging to file rather than terminal