You could make use of the script
command which will make a typescript file of everything printed to your terminal. It creates a forked shells and will record everything until that shell is exited.
$ script my_output
Script started on Tue 28 Nov 2017 09:46:15 AM UTC
$ whoami
ajefferiss
$ exit
Script done on Tue 28 Nov 2017 09:46:27 AM UTC
Then if I cat my_output
I get the same output:
$ cat my_output
Script started on Tue 28 Nov 2017 09:46:15 AM UTC
$ whoami
ajefferiss
$ exit
exit
Script done on Tue 28 Nov 2017 09:46:27 AM UTC