made output into file